在使用asp。net做网站的时候,经常遇到runtime error的运行时错误,提示基本一样,如下:
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>
 
今天使用VSS2005配置基于http的远程访问,进行 远程的版本控制。一切做好之后,提示这个错误。因为这个市vss自己创建的网站,也出错我就很迷惑了。请问高手们是如何解决这个问题的?
一般在使用asp。net编写网站的时候怎样调试?

解决方案 »

  1.   

    <configuration> 
        <system.web> 
            <customErrors mode="On"/> //或者RemoteOnly
        </system.web> 
    </configuration> 这样调试的时候再本地就可以看到详细的出错信息了,便于调试
      

  2.   

    用文件系统调试,发布到iis上,如果iis报错你可以到服务器上看一下错误信息。
      

  3.   

    Sorry,写错了,应该是Off不是On
      

  4.   

    你的错误可能是操作文件的时候产生权限问题
    把asp.net帐户所以权限都给它就可以了