Detect .net Framework version running

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have an app that was built with .net 1.1.

It loads but does not work with 2.0.

On starting the application I want to add a check to see the version of
framework that is running and if it is 2.0 add an error. how do I do this?
 
On starting the application I want to add a check to see the version of
framework that is running and if it is 2.0 add an error. how do I do this?

Check System.Environment.Version


Mattias
 
Assuming you can load your app enough to get it started, Environment.Version
will return a Version telling what runtime you're running under.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top