Asp.net '中的服务器错误/';应用程序(目标框架)
我有一个在Framework3.5中开发的web应用程序。我改为更新版本的Framework4.0。如果我在本地主机上运行相同的程序,它运行得非常好,但是一旦我把它放到web服务器上,它就会给我以下错误Asp.net '中的服务器错误/';应用程序(目标框架),asp.net,.net-4.0,configuration,webserver,Asp.net,.net 4.0,Configuration,Webserver,我有一个在Framework3.5中开发的web应用程序。我改为更新版本的Framework4.0。如果我在本地主机上运行相同的程序,它运行得非常好,但是一旦我把它放到web服务器上,它就会给我以下错误 Configuration Error Description: An error occurred during the processing of a configuration file required to service this request.Please review the
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:
<compilation debug="true" targetFramework="4.0">
配置错误
描述:处理配置文件时出错
服务此请求所需。请查看具体错误
请参阅下面的详细信息,并适当修改配置文件。
分析器错误消息:无法识别的属性“targetFramework”。
请注意,属性名称区分大小写。
源错误:
请帮帮我。在IIS服务器上安装.Net Framework 4.0的代码中,我需要做什么更改 当web.config中的属性为
targetFramework=“4.0”
但应用程序池设置为运行ASP.NET 2.0
时,通常会发生这种情况
ASP.NET 2.0
- 因此,将其更改为2.0不会产生预期效果
C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319>aspnet_regiis -i
看看这个:
希望这能解决您的问题。您是否检查了
应用程序池
是否在Framework 4.0
上运行?