State District Judge Tom Greenwell's body was discovered at about 7 p.m., 2 hours after the Corpus Christi courthouse closed, the Corpus Christi Caller-Times reported.
Greenwell was the first Republican to be elected a judge in Nueces County. He won his first election in 2001 and was re-elected in 2006 and 2010, running unopposed in that race. He lost an election for the appeals court in 2012.
The Nueces County Sheriff's Office released little information about the investigation Monday night. Sheriff Jim Kaelin confirmed Greenwell had been shot.
Most visitors to the courthouse are required to pass through metal detectors. Judges who have concealed carry permits are allowed to bring their guns to work.
Members of Congress to keep receiving porn magazine
Iranian woman stops the execution of son's killer