-
Timeout error
If I leave a Tornado page open for a period of time (30 minutes, say), I get the
`Object reference not set to an instance of an object.' error. I presume this is because it has timed out. I can't find any way of trapping this error so that I can either display a friendly message or take the user to another page.
Any suggestions?
Thanks
Bob
-
This not seems like the right message for timeout. You can trap this message in the config file. I have seen some articles before in this aspect.
Frank
-
Application error code
I think this is the code you were talking about. It adds an entry in the Application Event log - courtesy of Microsoft:
Sub Application_Error(ByVal sender As Object, ByVal e As EventArgs)
rem ************* 18th March 2005 - Application Error trap ***********
rem ** Creates Event in Application Event log - can use to redirect ****
rem ** to Error page ************************************************** *
rem ************************************************** ******************
Dim objErr As Exception = Server.GetLastError().GetBaseException()
Dim err As String = "Error Caught in Application_Error event" & _
System.Environment.NewLine & _
"User: " & session("g_Fullname") & _
System.Environment.NewLine & _
"Error in: " & Request.Url.ToString() & _
System.Environment.NewLine & _
"Error Message: " & objErr.Message.ToString() & _
System.Environment.NewLine & _
"Stack Trace:" & objErr.StackTrace.ToString()
EventLog.WriteEntry("EasyOcis: ", err, EventLogEntryType.Error)
Server.ClearError()
'additional actions...
End Sub
-
The one I've seen is in the Config file and redirect the error to an URL. I'll look up the article.
It is the custom error element in the config file.
http://msdn.microsoft.com/library/de...orsSection.asp
Frank