A student recently charged in a robbery fired a gun into the ceiling of his high school gym and then killed himself in front of about 150 classmates, police said.

Jajuan Holmes, 18, fatally shot himself about 10 a.m. at Davidson High School, police Chief Phillip Garrett said. He described the shooting as an isolated incident and said no one else was injured.

Holmes was charged a few weeks ago in a Dairy Queen robbery, which may have been a factor leading to the shooting, Garrett said. But he said the teen's death remained under investigation.

He said there had been no indication that Holmes might be suicidal.

Chelsea Smith, a fourth-year student, said she was seated in the gym bleachers when Holmes appeared at the top of the bleachers and walked down to the center of the gym court.

"He had a gun to his head," she said.

Smith said a coach walked toward Holmes, who pointed the gun at the coach until the coach retreated. She said Holmes then fired into the ceiling and shot himself.

Grief counselors were sent to the school, said Nancy Pierce, a spokeswoman for the Mobile County school system. She said classes would resume Friday.