Wyoming County Sheriff's Department officials have called off their search for a man who escaped police custody during an arraignment Friday morning. 

Dylan Perry, 25, was in custody and scheduled to be arraigned on charges of criminal trespassing and aggravated unlicensed operation of a vehicle at Attica Village and Town Court. 

While in the courtroom waiting to be arraigned, Perry went out a back door, down the stairs and escaped. He is still in handcuffs. 

He was wearing a gray hoodie and white t-shirt at the time of his escape. 

Attica and Alexander schools were locked down for a few hours Friday during the search.