0

I'm getting this runtime error sometime when I try to use asp.net application.

I'm getting this error when my browser windows is open for long time and I does not work on this.. might be server time

Is it because of login timeout ?

enter image description here

Neo
  • 15,491
  • 59
  • 215
  • 405

1 Answers1

2

I do not believe there is any way to tell from this error message what the problem is. As the error message states, the current settings prevent the actual error message from being displayed! You need to change the settings so you can actually see the error message, that will help you figure out what is causing it.

To do that, go into your web.config file and set (Note Off has capital O)

On IIS6:

<configuration>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>    <---- Optional
    </system.web>
</configuration>

On IIS7:

<configuration>
    <system.webServer>
        <httpErrors errorMode="Detailed" />
        <asp scriptErrorSentToBrowser="true"/>
    </system.webServer>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>

Edit - adding some more information:

Hi ashuthinks, I see you have accepted my answer already, but just wanted to add a few more lines. If everything in your code is fine, and the website runs perfectly, and you only get an error message on your screen if you leave it idle for 20 minutes or so, it is possible you are hitting the session timeout. I don't have any experience with this, but I have heard of it happening.

One of the things you can try is to change the session timeout in your web.config :

There seems to be a nice article about this here: http://www.simon.kaulius.com/page_timeout_in_asp_net.htm It talks about modifying web.config, and making changes in IIS and global.asax to redirect the user to another page on timeout.

There alsoseems to be a thread dealing with a timeout issue on stackoverflow: Session timeout in ASP.NET

Community
  • 1
  • 1
Gary
  • 1,735
  • 4
  • 19
  • 36
  • I wanted to add code to disable custom errors, not sure if I can do that as a comment. Plus I am thinking the OP will probably figure out what the actual issue is once he does this. – Gary May 15 '13 at 15:43
  • Ok thanks but I'm getting this error when my browser windows is open for long time and I does not work on this.. might be server time out ?? is it?? – Neo May 15 '13 at 17:45