What's the best way to attract a pile of threatening lawyers' letters from Microsoft? Sell pirate copies of Windows? Write a DRM-busting program?

Londoner Jamie Cansdale has just discovered a new approach. He had the temerity to make Redmond's software better.

As a hobby, Cansdale developed an add-on for Microsoft Visual Studio. TestDriven.NET allows unit test suites to be run directly from within the Microsoft IDE. Cansdale gave away this gadget on his website, and initially received the praises of Microsoft.

In fact, Microsoft was so pleased with him, it gave him a Most Valuable Professionals (MVP) award, which it says it gives to "exceptional technical community leaders from around the world who voluntarily share their high quality, real world expertise with others".

However, his cherished status did not last. In December 2005, he started getting emails from a Microsoft executive called Jason Weber. The problem was that TestDriven.NET supported the Express edition of Visual Studio. Express is the cut-down version that anyone can download for free from the Microsoft website. It is limited in various ways, and is intended only for hobbyists and students. Everyone else is supposed to shell out for the paid-for versions.

In fact, as a .NET hobbyist himself, Cansdale says he used Express to develop TestDriven.NET. Ironically, he only got access to a fancier version of Visual Studio as part of his MVP goody-bag.

But MS doesn't want you supporting Visual Studio Express with your add-ons.

Weber wrote to Cansdale that he had violated Express licence agreements: that he was accessing APIs not available to those who only had the Express version of Visual Studio, or that he had reverse engineered APIs - also forbidden.

Cansdale said from the off - and has stuck by this - that he only used APIs in the public domain, published on Microsoft's MSDN website for all to see. He invited Weber to be specific about the API/licence term that was violated.

Weber blanked him, and then began an exchange of increasingly acrimonious correspondence, which can be read on Cansdale's website here and here.

In the long sequence of emails that followed, Weber treated Cansdale with immense condescension:

"Craig Symonds is a busy Microsoft executive. We're fortunate that we could get 30 minutes with him for a conference call"; consistently evasive when asked to identify the specific legal problem, meanwhile trying to bully Cansdale to withdraw Visual Studio Express support and remove his "hack".

Cansdale took legal advice, and bravely dug in his heels.

At one point, in a splendid example of the right hand being unaware of who is getting the left hand's index finger, Cansdale got a letter presaging another MVP award only to have it hastily withdrawn the next day (find this incident the bottom of the second page of emails.)

Finally, Microsoft lost patience, and in the last few days has hit Cansdale with a flurry of lawyers' letters, also available on his website [see here and here]. Cansdale now has until 4pm Wednesday 6 June to disable the Visual Studio Express features of his product.

We await the deadline with bated breath.

Meanwhile, a quiet word in the ear of any earnest young programmer who is considering downloading a copy of Visual Studio Express and slaving deep into the night, striving hard in the Microsofty ways, in the hope one day of earning the glorious rank of MVP.

Do ya feel lucky, punk? ®