NEW YORK (CBSNewYork) — Police have taken into custody a man they say struggled with a federal agent and tried to take his gun.

Police had been searching for Ricardo Ruiz-Rosado for five hours before tracking him down, CBS2’s Valerie Castro reported.

READ MORE: Fashion World Remembers Iconic Journalist André Leon Talley

A Drug Enforcement Administration agent was trying to arrest Ruiz-Rosado around noon Tuesday in the parking lot of a Hampton Inn in South Jamaica on 135th Avenue near JFK Airport.

NYPD officers search for a suspect after a struggle for a DEA agent's gun in Queens on Nov. 3, 2015. (credit: CBS2)

NYPD officers search for a suspect after a struggle for a DEA agent’s gun in Queens on Nov. 3, 2015. (credit: CBS2)

READ MORE: New York Attorney General: Trump Organization Misled Banks And Tax Officials

One shot was fired, but no one was hit. The agent recovered the weapon.

The suspect ran off, and police swarmed the area. Ruiz-Rosado was found hiding in a shed, cops said.

MORE NEWS: Mayor Adams Vows Crackdown On Drivers And Cyclists Who Fail To Yield For Pedestrians: 'Stop, Let Them Cross'

Police also arrested a woman earlier Tuesday in connection with the case. They have not released her name.