PDA

View Full Version : creating Error status code



rakeshashapur
09-29-2010, 11:34 AM
hi
I want to create my own error status code.. so that i can use that code in web.config file to open a custom error page in the case of error generation in my application.
ex

<customErrors mode="On" defaultRedirect="Default2.aspx">
<error statusCode="20(my status code for error)" redirect="Default2.aspx" />
</customErrors>

please help me to solve this.........
its urgent

SresSi
10-29-2010, 11:05 AM
Hi,

way not use try catch (c#)? Into catch you can Redirect to your custom error page and also send custom message to show it to client.