Question on Environment.Version

J

Jalil

I am using VS2008 and made sure I am using Framwork 3.5 using instructions I
just received in this group. I read somewhere that you can get the version
you are using with the following code:

Console.WriteLine(".Net Framework Version
{0}",Environment.Version.ToString());

I did that and I get version 2!! I have 3.5 installed. Should I ignore this?
I have already set the framework to 3.5 in the properties of the project.

Thanks,

-Jalil
 
N

Nicholas Paldino [.NET/C# MVP]

Jalil,

The Version property on the Environment class is correct. It returns
the version of the CLR (according to the documentation) NOT the framework.
The CLR for .NET 3.0 and .NET 3.5 is the same CLR from .NET 2.0.
 

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

Top