I've done a lot of programming in MS Visual Basic using version 6.0 but recently I have been switching over to VB.NET 2003. One application (Coordinate Exchange) that I wrote in 6.0 was an plug-in for MapPoint. This application has been been fairly popular among MapPoint users and for a while now I've wanted to convert it to a more stable VB.net version. I knew converting wouldn't be easy but I couldn't even get past the first gate. For nearly a year now I had been trying to create an add-in for MapPoint using VB.NET and constantly running into a brick wall. I could setup the application just fine (see instructions here) but for some reason I could never get the runtime debugging to work. The application would run fine if installed but always crashed silently when entering debug mode. I had literally been trying to figure this out for the past year (from as early as May 10, 2004)... I searched the web, posted multiple requests for help to forums and news groups, and even sent an e-mail to a MapPoint developer (Chandu Thota) and never got any response. I was really shocked that nobody appeared to be having the same problem. Was it just me? I tried on several of my machines and each had the same problem. I was stuck.

I'm glad to say that I've finally solved it. Or actually somebody else solved it for a similar situation and I finally came across the answer. See the problem was not me or my application but the fact that every machine I owned had Microsoft .NET Framework version 2.0 installed. When MapPoint would open the addin it would load the version 2.0 by default. Visual Basic.NET 2003 would be attempting to debug assuming version 1.1. The application would then crash without any error message.

The solution is actually very simple. You have to instruct MapPoint to use the NET Framework 1.1. To do this create a file in the MapPoint directory (the one containing MapPoint.exe) named MapPoint.exe.config. The file should contain the following text:

    <supportedRuntime version="v1.1.4322">

After that all MP plug-ins run using 1.1 runtime and there are no more crashes in debug mode. Now all I have to do is spend the next year or so and convert all my 6.0 code to .NET. Wish me luck.