A prosecutor killed himself as police tried to serve him with an arrest warrant alleging he solicited sex with a minor, authorities said.

Louis"Bill"Conradt Jr., 56, chief felony assistant district attorney for nearby Rockwall County and former district attorney in Kaufman County, died Sunday.

Police forced their way into Conradt's Terrell home after hearing a gunshot when he refused to answer the door, a police spokesman said. The officers found Conradt with a self-inflicted gunshot wound and he later died at a hospital in Dallas, about 30 miles west of Terrell.

Police in the town of Murphy, in nearby Collin County, said Conradt solicited sex from a decoy posing online as a 13-year-old, said Murphy Police Sgt. Snow Robertson.

The Dallas Morning News reported that the warrant resulted from a sting operation conducted by Perverted Justice, an Internet watchdog group, and NBC's news magazine"Dateline."The sting lured men seeking sex with children to a house in Murphy; police said Conradt had not gone to the house but they believed he would.

Murphy Mayor Bret Bishop told the newspaper that he hopes his town won't be used again as a trap for child predators.

"I think it's a noble cause, but our police department is hired to serve and protect our citizens, and not to expose them to outside threats,"Bishop said.

Conradt was Kaufman County's elected district attorney for more than two decades before resigning in 2002 to run for a judgeship. He lost and later took the Rockwall County job.

Copyright 2006 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.