Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Microsoft .NET compatibility

I used VS2010, and target for .Net 2.0 (VB.Net Windows Form application)

How to decide what is the .Net target I decided on 2.0 because I understood it will be OK if the users have higher version

I tested my app on XP with .Net 2.0, works fine.

I uninstalled .Net 2.0 [to see what error message users might get]

[a few files were still left in C:\Windows\Microsoft.Net\Framework\v2.0.50727 but not all files]

I installed .Net 4 [. . . also needed to install Windows Installer 3.1, and Windows Imaging Component, as pre-requirments . . .]

but now when I run my app I get the error - "unable to find a version of the runtime to run this application"

so what should I recomend my clients? to install 2.0?

Thanks,

Atara

Update: I am going to recommend my XP users to install .Net 3.5 SP1

like image 998
Atara Avatar asked Sep 01 '10 17:09

Atara


2 Answers

A .NET 2.0 application needs .NET 2.0 to run. A .NET 3.0 or 3.5 application only needs .NET 2.0 plus whatever additional .NEt 3.0/3.5 assemblies it actually uses.

A .NET 4.0 application needs the .NET 4.0 CLR, so .NET 4.0 must be installed.

like image 173
John Saunders Avatar answered Sep 16 '22 21:09

John Saunders


You have two choices:

  • Recommend your clients install .NET 3.5 SP1 (nobody installs .NET 2.0 anymore)
  • Target .NET 4.0 and ask your clients to install .NET 4.0 (this might not be accepted very well especially if your clients are some large corporations where company policy doesn't allow it)
like image 39
Darin Dimitrov Avatar answered Sep 16 '22 21:09

Darin Dimitrov