Configuration interface configuration file clearly stated (application error occurred on the "/" server) error message

Server: IIS

Development Environment: .net

In fact, before these problems (as shown below) have been met and off several times but each time has not quite got the idea or know where is wrong, but similar to the figure somehow in this description, it is more difficult to troubleshoot
At this point you need to set the node in the configuration file, an error message will be clear that, in order to troubleshoot

"/" Application server error.


Runtime Error

Description:  An application error occurred on the server. The current custom error prevent the details of the application error from remote viewing (for security reasons) settings for this application. But can be viewed by browsers running on the local server computer. 

Details:  To enable others to view the details of this specific error message on the remote computer, located in the currently created "web.config" configuration file in the Web application root directory of a <customErrors> tag. "Mode" attribute flag set then this should <customErrors> is "Off".

<!-- Web.Config 配置文件 -->
<configuration>
    <system.web>
        <customErrors mode="Off"/>
    </system.web>
</configuration>

Note:  By modifying the application <customErrors> configuration tag "defaultRedirect" attribute, to point to a custom error page URL can be used to replace the current custom error page error page seen.

<!-- Web.Config 配置文件 -->
<configuration>
    <system.web>
        <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
    </system.web>
</configuration>

 

In fact, this point has been very clear hints, configuration node in the configuration file

<system.web>
        <customErrors mode="Off"/>
</system.web>

At this time, the server can run again the exact error message released (my error message is no access to a folder) with the error message, you can accurately repair

 

"/" Application server error.


Runtime Error

Description:  An application error occurred on the server. The current custom error prevent the details of the application error from remote viewing (for security reasons) settings for this application. But can be viewed by browsers running on the local server computer. 

Guess you like

Origin www.cnblogs.com/openWorld/p/11028483.html