Baltimore County police say a man accused of shooting his ex-girlfriend outside a hospital has died after he shot himself when police tried to arrest him.

The department said in a news release that 29-year-old Erwin Acree of Baltimore died Wednesday at Shock Trauma in Baltimore.

Police had obtained a warrant charging Acree with attempted murder in the shooting late Tuesday near MedStar Franklin Square Medical Center in Rossville. Police say the woman, whom they did not identify, was shot several times as she walked to a bus stop from her job at the hospital. Officers did not know the woman's condition.

After the shooting, investigators identified Acree as a suspect and tried to arrest him in Baltimore. Officers say Acree barricaded himself in a home and shot himself.