开发者

ASP.NET MVC 2, .NET 4 IIS 6 and Unrecognized attribute 'targetFramework'

开发者 https://www.devze.com 2023-01-25 20:46 出处:网络
I am getting a very frequented error ( as I could find from web) but none of the solutions have helped me

I am getting a very frequented error ( as I could find from web) but none of the solutions have helped me

I am deploying ASP.NET MVC 2 Project with Target Framework as 4.0 on IIS 6 . Thanks to Phil Haack I was able to configure IIS 6 to recognize URL Routes but now I am facing another issue

ASP.NET MVC 2, .NET 4 IIS 6 and Unrecognized attribute 'targetFramework'

I have made sure of the following:

  • Web service extension has 4.0.30319 enabled/ Allowed

  • Have created a separate Application

    pool for this website

  • My website has been configured with correct ASP.NET Version 4.0.30319

    开发者_高级运维
  • .aspx is mapped to right verion :

    c:\windows\microsoft.net\framework\v4.0.30319\aspnet_isapi.dll

  • Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053

What I think is interesting is that (ans as you can see in the screenshot) the page seems to indicate that the website is using Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053

Please help me get around this issue.

Thank you,

Mar


I know that on iis7 to get it work need specify .net framework version for app pool. Mb here also need to change version of framework from 2 to 4.


All,

I am answeing my own question -
on IIS 7 changing the application pool works but on IIS 6 I couldnot make code compiled in framework 4 work.

I downgraded my application framework to 3.5 ( ASP.NET on 2.0.50727). I tried for two days all workarounds and then decided to take this path to save time.

On my Application Server , I unregistered (ASPNET-REGIIS with option -u) asp.net framework 4.0.30319 and registered on 2.0.50727 (ASPNET-REGIIS with option -r)

This decision was also taken on the fact that our IT Dept dont have any plans to upgrade servers to 2008 and IIS 7 in near future.

Regards,

Mar

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号