CustomErrors -WebConfing

G

Guest

I have a Custom Error below..!!
But when i try it it doesn't work.
Am i suppose to make any changes in IIS for this to Work?
And the Error pages for example "AccessDenied.aspx" where should they be PUT?

<customErrors defaultRedirect="ErrorPage.aspx" mode="On">
<error statusCode="500" redirect="servererror.aspx" />
<error statusCode="404" redirect="filenotfound.aspx" />
<error statusCode="403" redirect="AccessDenied.aspx" />
</customErrors>
 
B

Bryce Budd

Patrick,

You'll need to remove your <error ....> tags for the custom error to go to
your defaultRedirect page.

If you need custom handling for 500, 404, 403 etc.. along with a generic
error messge you'll need to write that code in ErrorPage.aspx (check the
HttpResponse.Status, HttpResonse.StatusCode, and
HttpResponse.StatusDescription documentation)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,819
Latest member
masterdaster

Latest Threads

Top