A
ad
I have set customErrors to On and set a defaultRedirect in Web.config like:
<customErrors mode="On"
defaultRedirect="~/ErrorPage/GenericErrorPage.aspx">
When I throw a exception in Global.asax like:
throw new Exception("This a Error Test !!");
It will not redirect to GenericErrorPage.aspx, but if I throw the same
Exception in other web pages, it do.
What is problem? Can't customErrors do in Global.asax?
<customErrors mode="On"
defaultRedirect="~/ErrorPage/GenericErrorPage.aspx">
When I throw a exception in Global.asax like:
throw new Exception("This a Error Test !!");
It will not redirect to GenericErrorPage.aspx, but if I throw the same
Exception in other web pages, it do.
What is problem? Can't customErrors do in Global.asax?