欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  IT编程

Asp.Net 程序错误Runtime Error原因与解决

程序员文章站 2024-03-08 08:01:45
runtime error description: an application error occurred on the server. the current cu...
runtime error
description: an application error occurred on the server. the current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). it could, however, be viewed by browsers running on the local server machine.
details: to enable the details of this specific error message to be viewable on remote machines, please create a <customerrors> tag within a "web.config" configuration file located in the root directory of the current web application. this <customerrors> tag should then have its "mode" attribute set to "off".

<!-- web.config configuration file -->
<configuration>
<system.web>
<customerrors mode="off"/>
</system.web>
</configuration>

notes: the current error page you are seeing can be replaced by a custom error page by modifying the "defaultredirect" attribute of the application's <customerrors> configuration tag to point to a custom error page url.

<!-- web.config configuration file -->
<configuration>
<system.web>
<customerrors mode="remoteonly" defaultredirect="mycustompage.htm"/>
</system.web>
</configuration>
真实原因:.net装了以后,没有正常注册到iis

解决办法:
c:\windows\microsoft.net\framework\v1.1.4322\aspnet_regiis.exe -i
c:\windows\microsoft.net\framework\v2.0.50727\aspnet_regiis.exe -i