find a location for property in a new city

Wednesday 24 March 2010

Unrecognized attribute 'targetFramework' when upgrading to .NET 4

I received and error saying "Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive." with a description of "An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately."

Unlike .NET v3 and v3.5 which were essentially extensions to v2. .NET4 is an entirely self contained brand spanking new (and much lighter) framework. As such you will need to change your application pool like so:

Go to IIS and find the Application Pool you are using. Right click it and select Basic Settings then simply change the target framework to .NET Framework v4 as illustrated.

Follow britishdev on Twitter


  1. ain't working ,, still the same error !! :(

  2. worked for me mate. sure you got the right application pool?

  3. Didn't exactly help, but try this fix that worked for me. I posted the response here (search for ‘goHiker’):

  4. Works for me. Thanks.

  5. Great, exactly what I needed to make it work.