Application_Error Public event not being handled

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Dirc Khan-Evans (dirc.khan-evans_at_eqos.com)
Date: 03/25/04


Date: Thu, 25 Mar 2004 11:33:45 -0000

Hi folks.

In my app, I have an application level error handler. This works on several
development machines but once in the production environment, it fails,
reverting to the customErrors setting in the web.config.

I realise that if there are any exceptions thrown by this, then it would
fall through to the customErrors setting in the web.config, so to make sure
this didn't happen, everything has a try/catch block, which would log
everything. Problem is, nothing is logged, ie does not seem to be caught and
I can't see where it could fail.

Has anyone else seen this happening? Any ideas how to solve it?

Structure of error handler:

Application_Error(Object sender, EventArgs e)
{

    try

     {

            Exception lastError = Server.GetLastError().InnerException;

            //Generate error message and store in Session, Log the exception
and Server.Transfer to error page which reads the Session ErrorMessage

    }

    catch(Exception ex)

    {

            //log any problems

    }

}

The only difference between production and development environments is the
fact that we are running Application Centre on production with 3 web
servers. In both environments we are using StateServer for Session
managment... very little session data is stored.

Dirc



Relevant Pages

  • Re: How to limit access to production data from non-production code?
    ... Have separate development and production ... Never mix development, test and production environments. ... I generally have three separate system environments - development, ... colin DOT butcher AT xdelta DOT co DOT uk ...
    (comp.os.vms)
  • Re: Security around Solaris 10 zones
    ... trust relations between the automount daemon and the kernel ... >would you feel confident in putting them into sensistive production ... >development/test environments and less sensitive prod environs, ... to opinions held by my employer, Sun Microsystems. ...
    (comp.unix.solaris)
  • RE: BAM Excel live book
    ... We have various BizTalk environments setup, Development, ... User Acceptance Testing and Production ... We have Office XP installed only on our development server ... >>Is it possible to create BAM infrastructure using XML ...
    (microsoft.public.biztalk.general)
  • Re: How to limit access to production data from non-production code?
    ... Have separate development and production ... > Never mix development, test and production environments. ... I returned to the task in hand, deleting the database for the next task. ... underway, and the recovery time was bearable, the most recent backup was ...
    (comp.os.vms)
  • Miscalculation of 2 fields?
    ... Once production is finished, ... SO, if I enter any value less than 50, it fails (as it ... Private Sub FinTotal_Exit ... Cancel = False ...
    (microsoft.public.access.forms)