§ 18.2-283.1. Carrying weapon into courthouse. It shall be unlawful for any person to possess in or transport into any courthouse in this Commonwealth any (i) gun or other weapon designed or intended to propel a missile or projectile of any kind, (ii) frame, receiver, muffler, silencer, missile, projectile or ammunition designed for use with a dangerous weapon and (iii) any other dangerous weapon, including explosives, stun weapons as defined in § 18.2-308.1, and those weapons specified in subsection A of § 18.2-308. Any such weapon shall be subject to seizure by a law-enforcement officer. A violation of this section is punishable as a Class 1 misdemeanor. The provisions of this section shall not apply to any police officer, sheriff, law-enforcement agent or official, conservation police officer, conservator of the peace, magistrate, court officer, or judge while in the conduct of such person's official duties.