A teenage gunman burst into the lunch room of an Ohio school Monday morning and opened fire, wounding four students before a K-9 unit caught him, local media report.

The shooting unfolded at Madison Junior/Senior High School in Butler County, where the 14-year-old suspect is a student. He now faces charges including attempted murder and making terrorist threats. It's not clear whether he targeted certain students or fired at random, Sheriff Richard Jones said.

The suspect bolted from the school after the shooting, got rid of his gun, and ran into a field before the K-9 unit caught him, the Journal-News reports. Investigators said he used a .380 caliber handgun, according to Fox 19.

We have received clearance from the Butler County Sheriff. Students at the MJSHS are currently dismissing as quickly as... Posted by Madison Local Schools on Monday, February 29, 2016

Two students were hurt by gunshots and two others apparently by shrapnel, Butler County Chief Deputy Anthony Dwyer said. One of the students is 15 and the others are 14. Each is in stable condition in the hospital.

The school lifted its lockdown after the sheriff gave the all-clear. "It was painful... hard to concentrate," parent Ken Gairland said as he drove to pick up his sons.

At least one of the victims was shot in the leg. The other injuries appear to be more serious, but not life-threatening.

At least two AirCare helicopters flew to the school. "I just cleared the scene there and it is hectic," Rodney Muterspaw, police chief of nearly Middletown, said.

Data curated by FindTheData

Butler County is roughly 30 miles north of Cincinnati. The district has about 250 junior high and 500 high school students, according to enrollment estimates in Ohio Department of Education records.

Click for more from Fox 19.

Fox News' Chad Pergram and The Associated Press contributed to this report.