Forum Moderators: open

Message Too Old, No Replies

Error Handling Experts - I need some input.

error handling in asp

         

scud924

8:14 pm on Jan 15, 2004 (gmt 0)

10+ Year Member



I have set up the custom errors in IIS 5 for Error 500 and 500-100 to forward to a custom error handling ASP page that gives a more friendly message and logs all details to a file.
The problem is that only certain ASP errors are forwarded to that page. Others, and I have no idea why, seem to use the App Debugging settings of the Application in the section called: Script Error Messages. There are only two options:
1. Send detailed ASP error message to client.
2. Send text error message to client.
I tried switching them to fix this situation to no avail. Is there any way to turn this off so that I can get all of my ASPs to be forwarded to my ASP error handling page that I've already made?

aspdaddy

3:02 pm on Jan 17, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You could achieve that result but its a little work. This is one approach, I'm sure theres many other ways

use "on error resume next" on all pages

Identify the lines where errrors occur and handle them like this:

intResult = 25/0 ' will cause error
if err.number <> 0 then
Response.Redirect error.asp
' server.transfer on IIS6
end if