Difference between ASP.NET and .NET framework version

10,737

Solution 1

No, the .NET Framework 3.5 version is simply a set of extra assemblies that are referenced in addition to the core .NET 2.0 assemblies, so calling System.Environment.Version.ToString() will always return 2.0.50727.4927 for all versions from .NET 2.0 up to .NET 3.5.

You're running .NET 3.5 if you're referencing .NET 3.5 assemblies.

Solution 2

You're getting the CLR version...not the Framework version.

Gets a Version object that describes the major, minor, build, and revision numbers of the common language runtime.

Framework 3.5 still runs on the 2.x version of the CLR.

Solution 3

ASP.NET is a web framework written in and utilizing the .NET framework.

What you are getting the the version of the .NET runtime that the ASP.NET site is running under.

This runtime has several extensions to it, and .NET 3.5 is one - it still uses the .NET 2.0 runtime.

You can consider your site to be .NET 3.5 if you have included those libraries and are using their features such as Linq. See wikepedia for more details.

Share:
10,737
cc0
Author by

cc0

Updated on July 02, 2022

Comments

  • cc0
    cc0 almost 2 years

    I realize this is probably a hopelessly newbie question, but what is the difference between the ASP.NET version and the .NET framework version?

    I am making an asp.net site using the .net 3.5 framework, but when I echo this;

    System.Environment.Version.ToString()

    I get "2.0.50727.4927".

    Is this then an ASP.NET 2.0 site? This seems odd since I am using visual studio 2008 and the .net 3.5 framework.