I've been developing an ASP.NET 4.0 application on my local machine, and today I tried to deploy it to the server. After deploying, I got the following message when trying to visit the site in my browser:
Parser Error Message: Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive.
Ok, no problem. That means the server's still running ASP.NET 2.0. I'll just upgrade it, right?
It hasn't been that simple.
First I installed the .NET Framework v4.0. I followed the instructions that I found at this link to enable the ASP.NET ISAPI DLLs in IIS. When I run "cscript iisext.vbs /listfile " I can see the ASP.NET 4.0 DLLs listed, and that they're enabled. However, the behavior of my application hasn't changed. I still get the same error message.
I suspect I need to change the ASP.NET version in the web site configuration in IIS. However, I can't find any way of doing so. When I right-click on either the website, the virtual directory housing my application, or the application pool in IIS, and then click "Properties" from the context menu, I expected to find an "ASP.NET" tab among the properties pages that would let me change the ASP.NET version for that site/application. However, there is no "ASP.NET" tab or properties page for some reason. Why not? How do I fix this and switch my app to .NET 4.0?
Again, this is Windows Server 2003 R2, I believe the IIS version is 6.