By selling long-term software contracts to big companies and government agencies.

A lot of these deals come due in Microsoft's June quarter. That gives Microsoft's sales force a chance to go in and get customers to add additional software.

For instance, maybe a company is already paying for the right to upgrade Office on all their desktops, knowing that they'll probably be upgrading every three to five years. Microsoft can go in and sell them SharePoint Server (for collaboration) and Lync Server (voice and instant messaging) as well.

That's exactly what seems to have happened this quarter.

Financial analysts who cover Microsoft know to look out for a number called unearned revenue. That represents money that Microsoft has collected -- it's already in the bank -- but hasn't yet recognized as revenue.

(There's a good reason for this odd accounting: when customers sign these contracts, they get the right to all software upgrades that Microsoft delivers over the term of the contract. But Microsoft hasn't finished building that software yet, so it sets the money aside and gradually recognizes it over the term of the payment.)

At the end of June, Microsoft had $17.1 billion of this unearned revenue. That's more than 15% ahead of last year -- and way ahead of what most analysts were expecting (around $15.7 billion).

In other words, Microsoft's sales force is doing a great job selling long-term license agreements for business software to its biggest customers.