Refusal of s17 leave for court appearance

Can RC refuses leave for a court appearance?
If they cant then - where is this said in law, case law or tertiary legislation /guidance?
If they can the would the patient not be committing an offence of failing to attend and would the RC be perverting the course of justice - ie if Ps evidence in court could change outcome?
Any advice would be helpful

That would be a brave or foolhardy RC, and I can’t imagine the circumstances where the question would arise. I’d go back to the discussion about arrest and detention under the MHA: some legal procedures (i.e. arrest, court appearance) are just things that, in practice, trump MHA detention status and MHA procedures. If a patient is too unwell to safely travel etc that would be a matter to raise with the court authorities and sort out what to do.
Mat Kinton (CQC National MHA Policy Advisor, personal capacity)