The code is below for both locations. I'm starting to think it has
something to do with settings in IIS or on the server.
Code that throws the error.
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Throw New Exception("Something didn't work right.")
End Sub
Code in the Application_Error event that resides in my Global.asax.vb
Server.ClearError()
Response.Redirect("error.htm")
"Marina" <so*****@nospam.com> wrote in message
news:Og**************@tk2msftngp13.phx.gbl...
Are you clearing out the errors afterwards?
"Andy G" <aj*****@iastate.edu> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl... For testing purposes I put a
Throw New Exception("Something didn't work right.") on the click of a
button on a page. In the application_error section of my application I
have a
Response.Redirect("error.htm")
Later I will had error logging and email functionallity to this but in
the mean time I just need the application to redirect to this error.htm
page. This works perfectly fine in another application I have. It seems
like the Applicaiton_Error is not getting called during an application
error.
Thanks