S
Seguros Catatumbo
Hello guys, i am trying to port my custom asp 3.0 error page to
asp.net.
I want to disable debugging in my asp.net projects but i want to show
the users a pretty page but that page should send me an email with the
details of the error.
On classic asp i just went to iis and mapped the 500 error code to
error.asp, which does this:
set objError = Server.getLastError()
numero = objError.AspCode
tipo = objError.Category
pagina = objError.File
descripcion = objError.Description
fuente = Server.HTMLEncode(objError.Source)
linea = ObjError.Line
iis = ObjError.ASPDescription
and i send all that info via email.
It is my understanding that i dont have to mess with IIS on asp.net. I
just set customErrors on web.config properly, and indeed i get the
pretty error page, but when i do this:
Exception ex = Server.GetLastError();
It always returns null. How can i make this work?
Also, on asp.net i dont seem to have the same info i get on classic
asp (code, category, file, descripcion, source, line...), how can i
get the same data?
asp.net.
I want to disable debugging in my asp.net projects but i want to show
the users a pretty page but that page should send me an email with the
details of the error.
On classic asp i just went to iis and mapped the 500 error code to
error.asp, which does this:
set objError = Server.getLastError()
numero = objError.AspCode
tipo = objError.Category
pagina = objError.File
descripcion = objError.Description
fuente = Server.HTMLEncode(objError.Source)
linea = ObjError.Line
iis = ObjError.ASPDescription
and i send all that info via email.
It is my understanding that i dont have to mess with IIS on asp.net. I
just set customErrors on web.config properly, and indeed i get the
pretty error page, but when i do this:
Exception ex = Server.GetLastError();
It always returns null. How can i make this work?
Also, on asp.net i dont seem to have the same info i get on classic
asp (code, category, file, descripcion, source, line...), how can i
get the same data?