CHARLOTTE, N.C. ( TheStreet) -- A US Airways ( LCC) pilot, fired 18 months ago after his gun discharged in the cockpit, has returned to work and is thanking his union for getting his job back.

Capt. James Langenhahn was stowing his .40 caliber pistol when it discharged as his plane was landing in Charlotte on March 22, 2008, after arriving from Denver. The bullet went through the cockpit wall and fuselage. Nobody was injured. Langenhahn was fired soon afterwards, but a federal arbitrator has ordered that he be reinstated after the US Airline Pilots Association filed a grievance.

"Had it not been for the support and aid provided by the US Airline Pilots Association, there would have been absolutely no chance of recovering my position," Langenhahn wrote in a recent letter to union president Mike Cleary. A copy of the letter was obtained by TheStreet.com.

Besides thanking the union and its grievance committee officers, Langenhahn also thanked hundreds of pilots who called and emailed him, and said that "dozens of our fellow pilots also made generous financial contributions to me," enabling him "to make the necessary payments to keep myself and my family going.

"My family and I experienced a lot of pain during this time but in the end it was the work and support of USAPA that brought this to a final and just conclusion," he wrote.

US Airways spokeswoman Michelle Mohr said the airline is abiding by the arbitrator's decision to reinstate Langenhahn, who is currently undergoing recurrent pilot training at the airline's flight training center in Charlotte.

If you liked this article you might like

Cramer: Wall Street's Game du Jour, Leapfrogging

Halliburton-Baker Hughes Merger Has Fair Shot at Regulatory Approval

Donald Trump: 'I Ran a Great Airline.'

Jim Cramer's Take on Comcast's Dead Merger Deal With Time Warner Cable

One Reason American Airlines (AAL) Stock Is Up Today