custom errors definitions

O

Ollie

If I define a custom error definition in the web.config for an asp.net web
site, e.g.

<customErrors mode="On" defaultRedirect="Error.aspx"/>

If an exception in the code causes the error.aspx page to be displayed, is
it possible to get that exception from the Page_Load of the error.aspx page?

Cheers in Advance

Ollie
 
H

Harshdeep Mehta

Hi,

you can write Session variable in Global.asax file and get that session in
customerror page.

event in global.asax file is
protected void Application_Error(Object sender, EventArgs e)

{

}

I hope this will help you,

Harshdeep Mehta
 

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

customErrors 1
CustomErrors not working on live host 1
HTTP Error 404 1
CustomError Problem 4
Frustrations with Error Logging 1
Custom Errors Not Working 4
Custom error form in asp.net web app 2
<customErrors 3

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,053
Latest member
BrodieSola

Latest Threads

Top