A 45-year-old Buffalo robbery suspect’s attempt to escape custody after he was taken to Buffalo City Court was foiled by Erie County Sheriff’s court deputies and Buffalo police officers about 11 a.m. Wednesday.

Fermain Rivera of 481 Busti Avenue was arrested Tuesday by Buffalo police and was facing further proceedings Wednesday on charges of robbery, criminal use of a firearm and criminal possession of a controlled substance when he jumped over a courtroom retaining barrier and ran down stairs to try to get to an exit door.

Erie County Sheriff Timothy B. Howard and Undersheriff Mark N. Wipperman said Rivera’s escape attempt was foiled without injuries to anyone. He remains jailed in the Buffalo robbery case and now also the attempted escape charges.