The 12-year-old boy charged Friday with bringing loaded guns into a Prince William County middle school walked into the main office with a red bandanna covering his face, pointed a rifle at employees, students and parents and ordered them to "get down," witnesses and law enforcement sources said yesterday.

Everyone in the office complied, and the boy said he did not want to hurt anyone, the witnesses and sources said. Police arrived a short time later, and the boy was arrested without incident.

The seventh-grader was ordered held without bail after his first appearance yesterday in Juvenile and Domestic Relations Court, prosecutors said. The proceedings were closed to the public because the boy is younger than 14.

Also yesterday, police announced that a second boy has been charged in Friday's incident at Bull Run Middle School in the county's Gainesville section. A 13-year-old from Haymarket was charged with conspiracy to possess firearms on school property, police said. He helped plan the incident but backed out at the last minute, they said. Juvenile intake officers released him to his parents, and a court date has not been set.

According to an affidavit to support a search warrant, which was filed in Prince William Circuit Court yesterday, the 12-year-old was planning with "several others a violent takeover" of the school and had researched the 1999 shootings at Columbine High School in Colorado for a class report.

"We don't know where it would have gone, but all indications are that this was an extremely dangerous situation and could have cost several lives," said Commonwealth's Attorney Paul B. Ebert. "Whether it would have reached the magnitude of Columbine, I don't know."

Police have said that the boy, who was dressed in full camouflage gear on the last day of school, was plotting to frighten or even kill students who had teased him and then hold hostages to extort money. The plan was thwarted when school officials locked down the building and police stormed it under a countywide plan developed after the deadly Columbine shootings.

Police seized computer equipment and guns from the boy's three-story townhouse on Brave Court, according to a search warrant.

Law enforcement sources said the student roamed parts of the school with a loaded rifle before police rushed the building.

Although the school was locked down and all students were held in their classrooms sources said the student got into the office and an adjacent hallway.

"The gun was definitely pointed at people," one source said. "We're still investigating the sequence of events and details."

Police officers from all areas of the county responded when the emergency code was broadcast as part of a comprehensive response plan the county implemented after the Columbine shootings. Police officials estimated that more than 100 Prince William police officers and sheriff's deputies and officers from nearby jurisdictions responded to the scene. They said the first entry team approached the school about 10 minutes after the 911 call was received.

Police said the boy was talking to a school administrator when the team spotted him; the gun was not pointed at anyone at the time. Officers approached the student from behind and ordered him to drop his weapon, and he complied.

The boy's mother, Naomi Lewis, 38, a cafeteria worker at the school, also was arrested and charged with possession of a weapon on a school property. Police said the mother drove her son to school Friday and saw several guns in her van. She locked the vehicle but did not report that the guns were there. Her son later retrieved the guns with a key to the van that his mother did not know he had, police said. She did not know of his plot, police said.

Lewis is scheduled to make her first court appearance this morning.

Her son's trial has been set for July 6, prosecutors said. State law prohibits juveniles younger than 14 from being tried as adults in Circuit Court, where the proceedings are open to the public. The boy is charged with possession of a firearm by a minor, use of a firearm in commission of a felony, conspiracy to commit abduction for money and conspiracy to commit murder.

Claiborne T. Richardson II, an assistant commonwealth's attorney who is prosecuting the case, said a Manassas lawyer, Marjorie Alexander, has been appointed to represent the 12-year-old. Alexander declined to comment, saying she had not been formally notified of her appointment.

Over the weekend, friends and neighbors said that they were surprised by the boy's actions. They said he was constantly teased about his weight, large glasses and style of clothes.

Staff writers Christina A. Samuels and Maria Glod contributed to this report.