A 30-year-old Douglas man has been given a two-year conditional discharge after a scuffle with police at a school.
Bobby Michael Williams was restrained by officers using Pava spray after the struggle.
He admitted resisting arrest while a second charge, of threatening behaviour, was withdrawn.
Williams had previously pleaded not guilty to both allegations.
High Bailiff Jayne Hughes also ordered Williams to pay £125 prosecution costs.
Prosecuting advocate Rachael Braidwood told the court that police were called to St Ninian’s High School on April 7 at 2.30pm.
Williams was visiting the school in relation to a parenting issue.
However, staff called the police after concerns over his behaviour.
When officers arrived they found Williams, who lives at Willaston Crescent, sitting in his car outside.
He was asked to get out but initially closed the car window.
Williams then got out and was described as agitated, which prompted a struggle to ensue.
He flailed his arms and then grabbed handcuffs and threw them away as officers were trying to cuff him.
Williams was eventually restrained using Pava spray.
After being taken to police headquarters, he handed in a prepared statement saying he had become agitated after officers had put their hands on him without warning.
He said he suffered from mental health issues.
In 2018, Williams was fined £500 for provoking behaviour.
A probation report said that he is engaging with mental health services and was a scaffolder but is currently unable to work.
Defence advocate Jim Travers asked for credit to be given for his client’s guilty plea.
He said: ‘Mr Williams had good intentions on the day but soon became involved in an unseemly scuffle with police.
‘He was agitated and somewhat surprised to be placed under arrest.
‘He wants to put the matter behind him. It has been quite a trauma for him and his family.’
The High Bailiff told Williams: ‘This was a serious incident of resisting police officers who were called by the school.
‘Pava spray being used must have meant you were a handful for them.’
Williams will pay the costs at a rate of £5 per week deducted from benefits.