asp.net - 运行时错误根本不知道该怎么办,我对这些事情没有经验

标签 asp.net asp.net-mvc-4 error-handling runtime-error

谁可以帮助我呢?我根本不知道该怎么办。从头到尾,我什至都不知道如何创建标签或什么都不做。帮我?尽快这是它的外观:

“/HRX”应用程序中的服务器错误。运行时错误说明:服务器上发生了应用程序错误。该应用程序的当前自定义错误设置可防止出于安全原因而远程查看该应用程序错误的详细信息。但是,可以由运行在本地服务器计算机上的浏览器查看它。

Details: To enable the details of this specific error message to be viewable on remote     machines, please create a tag within a "web.config" configuration file located     in the root directory of the current web application. This tag should then     have its "mode" attribute set to "Off".

Server Error in '/HRX' Application.
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>

最佳答案

如果您具有对服务器的远程访问权限,请尝试在本地浏览服务器上的页面。

否则,尝试将customerrors模式设置为“关闭”并部署它。

<customErrors mode="Off"/>

如果您采用上述任何一种方法,都希望看到Exception StackTrace。这可能会为您提供更好的错误提示。

关于asp.net - 运行时错误根本不知道该怎么办,我对这些事情没有经验,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21438669/

相关文章:

asp.net-mvc-4 - 使用 nonce 为登录页面添加书签

asp.net-mvc - 我可以对单个 RESTful Url 的 POST 和 GET 使用两种不同的模型吗?

c# - 提交后 IEnumerable 属性为空

php - Magopay未经授权的错误

haskell - Haskell类型错误消息

c# - 在 C# 中通过自定义属性名称获取复选框控件

asp.net - MVC 中不包含 'GetEnumerator' 的公共(public)定义

swift - Swift中 `try`关键字的用途是什么?

javascript - 如何使用 jQuery 或 javascript 获取 tabcontainer 的高度?

asp.net - 如何在jqGrid中实现多重搜索