M
Mr Newbie
I'm testing error handling configurations and having some trouble. I created
a WebForm called. ErrDefault.aspx and I am trying to use the Page error
attribute to force the redirection to a custom page, but I only get and
unhandled exception page and it does not direct me to my specific page. I'm
probably doing something really stupid, but I cant see what .
Any Ideas ? - Thanx Mr N
--------- DETAILS BELOW -----------
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="WebForm1.aspx.vb"
Inherits="Exceptions1.WebForm1" errorPage="ErrDefault.aspx"%>
In my button handler.
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
Throw New System.Net.WebException("Custom Error Page")
End Sub
Custom Error Page
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.Net.WebException: Custom Error Page
Source Error:
Line 33:
Line 34: Private Sub Button1_Click(ByVal sender As System.Object, ByVal
e As System.EventArgs) Handles Button1.Click
Line 35: Throw New System.Net.WebException("Custom Error Page")
Line 36: End Sub
Line 37: End Class
a WebForm called. ErrDefault.aspx and I am trying to use the Page error
attribute to force the redirection to a custom page, but I only get and
unhandled exception page and it does not direct me to my specific page. I'm
probably doing something really stupid, but I cant see what .
Any Ideas ? - Thanx Mr N
--------- DETAILS BELOW -----------
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="WebForm1.aspx.vb"
Inherits="Exceptions1.WebForm1" errorPage="ErrDefault.aspx"%>
In my button handler.
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
Throw New System.Net.WebException("Custom Error Page")
End Sub
Custom Error Page
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.Net.WebException: Custom Error Page
Source Error:
Line 33:
Line 34: Private Sub Button1_Click(ByVal sender As System.Object, ByVal
e As System.EventArgs) Handles Button1.Click
Line 35: Throw New System.Net.WebException("Custom Error Page")
Line 36: End Sub
Line 37: End Class