DIXON, Ill. (AP) — A judge has refused to lower bail for a teen charged with firing shots at an Illinois high school as seniors met for graduation rehearsal.

Matthew A. Milby Jr. appeared in court Friday via video from the Lee County Jail, where he’s being held on $2 million bail.

Police say the 19-year-old fired several shots inside Dixon High School on Wednesday before he was shot by a school resource officer in an exchange of gunfire.

Milby’s attorney asked Lee County Court Judge Ronald M. Jacobson to lower bail to $500,000, saying his criminal record is “nonexistent.” State’s Attorney Matthew Klahn said Milby is accused of “the most serious crimes you can commit.”

Milby is a senior at the school about 100 miles (161 kilometers) west of Chicago but has not been attending classes. His next court hearing is scheduled for Wednesday.