| re: Request Timeout Error Question
What I do for my error logging. (psuedo code)
Application_Error
Exception ex = Server.GetLastError();
Server.ClearError();
LogError( ex );
Session["ApplicationError"] = ex; //this will save it in session so I can
pull it from the
Response.Redirect( "ErrorPage.aspx", true ); //I am sure you could use
Server.Transfer, but we don't use Server.Transfer.
--in my ErrorPage
Page_Load
Exception ex = Session["ApplicationError"] as Exception
//display the exception.
This isn't exactly what I do; I switch off the exception type and have
different directions depending on the type of error.
bill
"Steve Taylor" <Remove_staylor@laborready.com> wrote in message
news:O8olgIbzEHA.2016@TK2MSFTNGP15.phx.gbl...[color=blue]
> So you're say that I should immediately execute "Server.ClearError()" and
> then within my error processing page access the most recent error by by
> calling Server.GetLastError()?
>
> "William F. Robertson, Jr." <wfrobertson_at_kpmg_dot_com> wrote in message
> news:OgAfnmazEHA.804@TK2MSFTNGP12.phx.gbl...[color=green]
> > In your Application_Error, you need to call Server.ClearError() or the[/color]
> error[color=green]
> > will still be sitting there and be sent to the default error page.
> >
> > Server.GetLastError() will also return the exception chain that caused[/color][/color]
the[color=blue][color=green]
> > error.
> >
> > HTH,
> >
> > bill
> >
> >
> > "Steve Taylor" <Remove_staylor@laborready.com> wrote in message
> > news:u%23U7jRZzEHA.1412@tk2msftngp13.phx.gbl...
> > Here's what happening:
> >
> > - I have a global error trap set in global.asax defined as:
> > protected void Application_Error(Object sender, EventArgs e) {
> >
> >[/color]
>[/color]
HttpContext.Current.Server.Transfer("/salesnow/errors/SalesNow_Error.aspx");[color=blue][color=green]
> > }
> >
> > - My users are on occassion are getting the error:
> > "Server Error in '/Salesnow' Application - Request timed out."
> >
> > - No aspx page is referenced anywhere in the *ugly* default error page.
> >
> > - My error trap is designed to e-mail me notices of errors.
> >
> > - I am seeing about twice as many errors logged in the Win2003 PerfMon
> > window for the web servers (as e-mails).
> >
> > - Is this happening because my re-directed error page is timing out?[/color][/color]
What[color=blue][color=green]
> > is the best way to trap for this?
> >
> > TIA,
> > Steve
> >
> >[/color]
>
>[/color] |