After shock R&D spending plans sent Microsoft’s shares into a deep dive a quarter ago the company had to do something pretty special to restore investor confidence in its stock. Such a massive buyback can’t but help in that end.

Also helping, the company raised its guidance for the new fiscal year as it reported its fourth-quarter results. New expected earnings for fiscal 2007 of $1.43 to $1.47 per share bettered its previous forecast of $1.36 to $1.41.

The combination of news sent shares up 5% to $24.11, which goes some way to turning around their recent decline.

A quarter ago, the company’s shares, hovering between $26 and $28 for the first half of the year, took a precipitous 11% dive to $24.15, its biggest single-day loss in years, and had not recovered since.

For the fourth fiscal quarter ended June 30, Microsoft saw 16% revenue growth, to $11.8bn. Net income was down 24% to $2.83bn, $0.28 a share, compared to $3.7bn and $0.34 a year earlier. Excluding the $351m European fine, profit was $0.31 a share, a penny better than estimates.

For fiscal 2006, the firm reported income of $12.6bn, $1.20 a share, on revenue up 11% at $44.28bn

Chief financial officer Chris Liddell said this return to double-digit top-line growth will continue in 2007. The next 12 months will probably see Microsoft ship new versions of Windows, Office, and a rumored new music player to challenge the Apple iPod.

The company expects its client business to be up 8% to 10% in fiscal 2007, matching the expected growth in the the PC market, with most of the growth coming in emerging markets and in the consumer space, and most of it loaded in the second half, after Vista ships.

Client was up 12% in the fourth quarter, to $3.38bn, with 13% revenue growth from PC makers offsetting a 6% rise in commercial and retail sales.

The server and tools division saw healthier 18% growth to, $3.18bn, driven largely by the release of SQL Server 2005 and Visual Studio. SQL Server revenue was up 35%.

Information worker, which includes the Office software, was up a more modest 6% to $3.13bn. Sales of annuity licenses for Office, as companies pay up prior to the release of Office 2007 was the driver there.

The much smaller business solutions division grew 16% to $280m, driven by Dynamics ERP and CRM suites. Mobile and embedded software sold $113m, up 41%.

The Xbox-heavy home and entertainment division saw revenue up 94% to $1.18bn, based on strong sales of the Xbox 360 console. Microsoft has shipped five million units to date, 1.8 million of which were sold during the fourth quarter.

As for the closely watched MSN division, where Microsoft has promised to invest heavily as it tries to rejuvenate its online properties as Windows Live, it was down 3%. And the company does not expect any big growth there for a while.

The online services unit is considered vital to Microsoft’s longer-term prospects. The company wants to position itself as a strong rival to Google Inc and Yahoo in the search advertising space, and as the platform of choice for web services development.

Advertising revenue at MSN, which now all comes from Microsoft’s own adCenter system, was flat, due to the transition from Yahoo! Inc’s ad system, and the internet access business was down 13%.

We’re looking forward to a good continuing year on the display [advertising] side and a transition year on the search side, Liddell said. He expects MSN to see revenue flat to down 4% in the first quarter, and up 7% to 11% for the full year.

While investors will have to wait for good news from MSN, and won’t see the full benefits of the Vista and Office launches until calendar 2007, Microsoft did give them some reasons to be cheerful.

The $40bn buyback will be split into two chunks. The first, a modified Dutch auction, that runs for the next month. Microsoft will attempt to buy up to $20bn of stock at between $22.50 and $24.75, eliminating up to 808 million, or 8.1%, of its shares.

The second $20bn tranche will be a more sustained, regular buyback, that could last until 2011. The company revealed it completed its last big buyback, of $30bn, ahead of schedule during the fourth quarter. That buyback was announced two years ago, and was slated to last four years.