A Riverhead man was arrested on grand larceny and drug charges Monday after he was caught stealing a 40-caliber handgun from a victim’s car.

Riverhead police said Edgar J. Castillo, 26, of Old Westhampton Road was being held on $30,000 cash bail and was scheduled to be arraigned on charges of fourth-degree grand larceny and third-degree criminal sale of a controlled substance.

His attorney could not be reached for comment.

PhotosRecent LI mug shotsDataLI crime stats

Police said they responded to Peconic Bay Medical Center after a victim reported the theft of a 40-caliber Glock handgun from a car parked at the hospital at 2:40 a.m.

advertisement | advertise on newsday

The officers launched an investigation that led to Castillo’s arrest and also uncovered his connection to an unrelated drug case, police said.

That case is being handled by the Suffolk County district attorney’s East End Drug Task Force, officials said.