Warning for running under wrong .NET version

I mentioned earlier that I went away and used some computers at a place a worked for 5 months last year. I had tree computers available and I started fresh with them each installation of WXSIM. 2 Dell and 1 Compaq, running XP Pro latest SP, only 256MB RAM though. They have a 25mbps asynchrounous line to the internet. My “old” collegue stated that .NET was installed and running, they had some .NET apps made in house…

Well, things did not go so well, quite many of the problems I seen and heard of appeared.

Then suddenly I realized, that what I had been working with at them last year was VB.NET 2005. Just asking my collegue if they had any older VB or .NET applications than that in use within any of their five sites around Sweden (they do quite different jobs at different places). - The answer was NO!

So, what we had tried was to run WXSIMATE not under .NET 1.1, but under 2.0 (I first thought). Well, I apparently is even more complicated than that. From what I read on the net a .NET application that is marked for, for example, .NET 1.1, but where 1.1 is not installed will run under the highest version number of .NET installed - in this case they also had .NET 3.0 installed.

The thing is also that even if the highest .NET version had been 2.0 it would probably have been problems - There is a quite large list of differences between .NET 1.1 and 2.0 found on MS web.

So we installed .NET 1.1 and everything went much better, but not flawless (I used my licensed version of WXSIM).

So, we used a utility, DOTNET.EXE to verify that it found .NET 1.1 installed. And I did that at home also, just to be on the safe side, but since I have used VB.NET 2003 / .NET 1.1 earlier I most certainly had it installed on all my computers. The thing is that I deleted/uninstalled VB.NET/VS.NET 2003, a month ago, using VS 2008. What I had wanted to do was to be able to test and verify for you what .NET version a .NET 1.1 app would use in the absence of 1.1.

There are .NET APIs being able to identify what version of the runtime is in use.
There are to basic methods -

The first is most often used by installation programs to detect via the registry if the .NET runtime version needed by the app to be installed is alreafy there or not.

The second is to detect, mainly under a startup of an application what version it is loaded under. The functionality comes from "Environment.Version.Major ". There are several samples found on the net of which one is http://geekswithblogs.net/dchestnutt/archive/2006/03/07/71661.aspx

Well,

The conclusion is, if you have problems at the very beginning of starting to use WXSIMATE. Start by verifying that you have .NET 1.1 installed (I suggest using dotnet.exe). But to be able to rule this out entirely as a possible source of problems, Tom could implement the check in WXSIMATE and give a warning and refuse to continue…

Cheers,

Ingemar