Ch 18 - Try it out: Handling Exceptions Site Wide (OtherErrors.aspx)
I've been reviewing the error handling and had a question on how to do a test to confirm that the OtherErros.aspx page works with an unhandled error.
I did the following steps:
1) First I created OtherErros.aspx as a standard web form.
2) I removed all the error handling from the SendButton_Click in the ContactFrom web form.
3) In web.config, I changed the pwd to an invalid password under the <mailsettings> <smtp> element.
I was hoping to force an exception when user tries to send an email via the Contact Us and see the website redirected to the othererros.aspx page, but don't see this page appearing.
I'm not sure what I'm doing wrong? Should these steps force the othererrors.aspx page to appear?