A man was in custody Tuesday, accused of firing shots from an assault rifle at an Atlanta area elementary school. No one was injured.

The 800 or so students in pre-kindergarten to fifth grade were evacuated from Ronald E. McNair Discovery Learning Academy in Decatur, a few miles east of Atlanta.

The suspect, identified later as Michael Brandon Hill, 20, fired at least a half-dozen shots with an assault rifle from inside the school and officers returned fire when the man was alone and they had a clear shot, DeKalb County Police Chief Cedric L. Alexander said at a news conference.

Although the school has a system in which people must be buzzed in, the gunman slipped inside behind someone authorized to be there, Alexander said. The suspect, who had no clear ties to the school, never got past the front office, where he held one or two employees captive for a time, and he was being questioned at the police department, Alexander said. No charges had yet been filed.

Complicating the rescue, bomb-sniffing dogs alerted officers to something in the suspect’s trunk and investigators believe the man may have been carrying explosives, Alexander said. Officials cut a hole in a fence to make sure students running from the building could get even farther away to a nearby street, he said.