Something NEW?.....Naaa...Not much.

↑ Grab this Headline Animator

Thursday 27 August 2009

Web.Config cleaned in .NET 4.0 & VS2010...

Yes...

The Web.config in .NET 4.0 is simplified and cleaned. Web.config in VS2008 SP1 is of 126 lines long and contains almost everything, including handler definitions, tag definitions and modules which are to be included in ASP.NET HTTP engine, and eventually, increase in size. The reason because .NET 3.0 and .NET 3.5 uses the same CLR and machine.config configuration file which are shipped with .NET 2.0
.NET 4.0 and VS 2010 includes a new version of CLR and a new .NET 4 specific machine.config file. .NET 4.0 is installed side-by-side with the one used by .NET 2.0, .NET 3.0 and .NET 3.5

The new .NET 4.0 machine.config file now automatically registers all ASP.NET tag sections, handlers and modules including the below functionalities
ASP.NET AJAX
ASP.NET Dynamic Data
ASP.NET Routing (for both ASP.NET web forms and ASP.NET MVC)
ASP.NET Chart Controls ( new with ASP.NET 4.0)

First section in web.config tells ASP.NET to enable debugging by default for the application, and indicates the version of .NET. Visual studio uses this to target when it shows us intellisense. VS2010 supports multi-targetting and the intellisense within the IDE will automatically vary based on the targetted framework version.
Second section tells whether to use "Integrated" mode when running ASP.NET application within IIS7.0, to control running ASP.NET HttpModules for all requests within the application or just for ASP.NET specific URLs.