I was getting the error "Unrecognized attribute ‘targetFramework’. Note that attribute names are case-sensitive" on an ASP .NET 4.0 website. This was caused by the application pool targeting the wrong .net framework, change the application pool to the correct .net framework and the error will be resolved.

 

Error

image

Solution

image

Tags: , ,

21 Comments on How to resolve: "Unrecognized attribute ‘targetFramework’. Note that attribute names are case-sensitive"

  1. Ed says:

    Thanks!

  2. meleave4 says:

    thanx

  3. The_squall says:

    Thanks for the tips!!!!! really usefull!!

  4. satish says:

    Thanks..it is working

  5. Brian says:

    It did not work for me.
    The version was set to v4.0.30319

  6. Mohammad says:

    Thanks,
    Really useful and resolved my problem :-)

  7. Roman says:

    I had the same problem but using VS’ virtual server not IIS.
    So here an article that could help you if you have the same problem:
    http://extremedev.blogspot.com.....to-vs.html

  8. Chris says:

    You may also get this error if you have opened a website (not using a solution) that was developed for in VS2010 framework 4.0 with VS2008 on windows XP. In this scenario the app is using XP’s webserver rather than VS2010’s built in webserver.

  9. prabhu says:

    thanks

  10. RCH says:

    How do you open the dialog box to edit the application pool?

  11. Waqas Ahmed Hijazi says:

    Very nice post, i was searching about the error for last one hour. But you have resolved my error.

    Thanks

  12. elaiyaraja says:

    in menu

    Website -> Start Options -> build tab – > Select Target Framework in combo box (.NET FrameWork 4)

  13. deepak says:

    Server Error in ‘/’ Application.

    Configuration Error

    Description: 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.

    Parser Error Message: Unrecognized attribute ‘targetFramework’. Note that attribute names are case-sensitive.

    Source Error:

    Line 10:
    Line 11:
    Line 12:
    Line 13:
    Line 14:

    Source File: D:\WEBDATA\highgradetutors.com\web.config Line: 12

    Version Information: Microsoft .NET Framework Version:2.0.50727.5448; ASP.NET Version:2.0.50727.5456

  14. Paladin says:

    thanks

  15. Nirmal says:

    thanks

  16. Jitesh says:

    Thanx it helps me…!
    Can u Tell me how to install IIS on Windows7 actuaaly I am facing problem during installing iis i.e. (Not full featurs are added)
    and IIS is not Install to my PC(I am Having Legal Windows7 version).

  17. Just go to Control Panel > Programs and Features > Turn Windows features on or off > Check Internet Information Services
    If you are installing it on a dev machine for the first time, make sure all subfolder checkboxes are checked, so you can play arround with all the features.

  18. Hardik says:

    hello really a good but i have a problem.

    i have .net 3.5 framewrok so as go to following path

    Website -> Start Options -> build tab – > Select Target Framework in combo box

    i found .Net FrameWork 3.5

    & the application i want to run on my pc is build in 4.o.
    so how do i solve this problem?

  19. ayelet says:

    Thanks, it solved the problem !

  20. Sanjeev says:

    Thank u so much. its solved my problem

  21. elmira says:

    hello,i have actually Hardik problem
    i have .net 3.5 framewrok so as go to following path
    Website -> Start Options -> build tab – > Select Target Framework in combo box
    i found .Net FrameWork 3.5

    so what do i do?i need help immediately

Leave a Reply