Trinity Industries (NYSE:TRN) shares rose more than 8% Friday on the heels of positive news about second-quarter earnings guidance. The maker of railcars, barges, and construction products appears to be benefiting from a "perfect storm" of positive developments for each business. However, the improved earnings forecast is only part of the story.

The Dallas-based company increased its outlook for the quarter to $0.35 to $0.42 from $0.25 to $0.32. In addition, Trinity forecasted that revenue for the quarter would exceed $700 million. If the guidance holds, it would mean that Trinity's year-over year EPS jumped by at least 483% while revenue rose 27.6%.

To some extent, the bump in the guidance is no surprise. Railroads like Genesee & Wyoming (NYSE:GWR), RailAmerica (NYSE:RRA), and Canadian Pacific Railway (NYSE:CP) have experienced burgeoning demand for their services, which likely has been a boon to Trinity's railcar manufacturing and leasing services. Further, Trinity noted last month that its inland barge group had signed $82 million worth of orders for 198 hopper barge units in the first two months of the second quarter. Finally, favorable weather has helped Trinity's construction segment perform well.

Unfortunately, Trinity's balance sheet has suffered in the midst of the boom. In the first quarter, cash and equivalents declined by 37.6%, to $113.7 million, compared with last year. Debt, meanwhile, rose more than 10% to $570.2 million. It's pretty easy to trace the source of the slumping cash position. Though Trinity's bottom line improved steadily from 2002 to 2004, its cash-generating ability suffered as the firm ramped up inventory levels to meet demand. Cash from operations crashed from positive $120.7 million in 2002 to negative $82.6 million in 2004; in the first quarter, Trinity again bled cash, although the $59.2 million used in operations was an improvement from the $71.7 million used in the same period last year.

While Trinity's improving earnings profile is certainly a positive, the income statement is clearly only part of the story. Trinity is not in any immediate danger; it has access to a $350 million credit facility. But investors should keep a close watch to make sure the firm doesn't overextend itself.

Fool contributor Brian Gorman is a freelance writer in Chicago. He does not own shares of any companies mentioned in this article.