Cause and solution of runtime error in ASP. NET Program

Source: Internet
Author: User

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 cocould, 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 shoshould 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>
Real reason: After. NET is installed, it is not properly registered to IIS

Solution:
C: \ windows \ Microsoft. NET \ framework \ v1.1.4322 \ aspnet_regiis.exe-I
C: \ windows \ Microsoft. NET \ framework \ v2.0.50727 \ aspnet_regiis.exe-I

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.