问题描述
我得到一个错误每次我上传我的web应用程序的供应商。由于的customErrors模式中,我看到的是默认的运行时错误的消息,通知我去关闭的customErrors查看更多有关该错误。
I get an error everytime I upload my webapp to the provider. Because of the customErrors mode , all I see is the default "Runtime error" message, instructing me to turn off customErrors to view more about the error.
激怒,我已经把我的web.config看起来像这样:
Exasperated, I've set my web.config to looks like this:
<?xml version="1.0"?>
<configuration>
<system.web>
<customErrors mode="Off"/>
</system.web>
</configuration>
和仍然,我得到的是与它没有任何有用的信息愚蠢的远程错误页面。
还有什么我可以做转的customErrors OFF!?
and still, all I get is the stupid remote errors page with no usefull info on it.What else can I do to turn customErrors OFF !?
推荐答案
这已经让我疯狂,在过去几天里,不能得到解决,但终于想通了:
This has been driving me insane for the past few days and couldn't get around it but have finally figured it out:
在我machine.config文件我有一个条目:
In my machine.config file I had an entry:
<deployment retail="true" />
这似乎覆盖您在web.config文件中所指定的任何其他customError设置,因此上面的条目设置为:
This seems to override any other customError settings that you have specified in a web.config file, so setting the above entry to:
<deployment retail="false" />
现在意味着我可以再一次看到,我需要将详细的错误信息。
now means that I can once again see the detailed error messages that I need to.
希望帮助别人那里,节省几个小时的拔头发。
Hope that helps someone out there and saves a few hours of hair-pulling.
这篇关于的customErrors模式=&QUOT;关闭&QUOT;的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!