Mathematics
Mathematics

Reputation: 7628

Which Machine.config to modify

I have installed 1,2,3,3.5,4 .net framework on my server, now they all have machine.config file, which one should I modify to see changes for my web applications in IIS 6.

Upvotes: 2

Views: 1670

Answers (1)

Mudassir Hasan
Mudassir Hasan

Reputation: 28751

Each version of .NET is installed in different folder and have different machine.config file independent of each other.

ASP.NET 1.x uses %WINDIR%\Microsoft.NET\Framework\v1.1.4322
ASP.NET 2.0 / 3.5 x86 uses %WINDIR%\Microsoft.NET\Framework\v2.0.50727
ASP.NET 2.0 / 3.5 x64 uses %WINDIR%\Microsoft.NET\Framework64\v2.0.50727
ASP.NET 4.0 x86 uses %WINDIR%\Microsoft.NET\Framework\v4.0.30319
ASP.NET 4.0 x64 uses %WINDIR%\Microsoft.NET\Framework64\v4.0.30319

To see which version your application is running on print

Response.Write(System.ConfigurationManager.OpenMachineConfiguration().FilePath);

Upvotes: 2

Related Questions