If you look at the event handler for the UnhandledException of the
Application object in your App.xaml.cs file, you'll see why.  By default,
unhandled exceptions are handled differently when a debugger is attached.

        private void Application_UnhandledException(object sender,
ApplicationUnhandledExceptionEventArgs e)
        {
            // If the app is running outside of the debugger then report
the exception using
            // the browser's exception mechanism. On IE this will display
it a yellow alert
            // icon in the status bar and Firefox will display a script
error.
            if (!System.Diagnostics.Debugger.IsAttached)
            {

                // NOTE: This will allow the application to continue
running after an exception has been thrown
                // but not handled.
                // For production applications this error handling should
be replaced with something that will
                // report the error to the website and stop the application.
                e.Handled = true;
                Deployment.Current.Dispatcher.BeginInvoke(delegate {
ReportErrorToDOM(e); });
            }
        }

Chris

On 22 April 2012 14:58, Greg Keogh <g...@mira.net> wrote:

> Chaps, I spent an hour this morning adding simple logging inside my new
> SL4 app. I added a button and a child window to display the stack of
> messages in a ListBox. It wasn’t much new code and it works fine and helped
> me locate the problem quickly once it was working. It’s a rather low-tech
> fix.****
>
> ** **
>
> It turns out I was parsing some bad XML and the null exception was getting
> swallowed somehow. I still haven’t figured out why it didn’t result in one
> of those ugly IE popups with a general SL error message. Had I received one
> of those popups I would have known instantly that I’d stuffed up my logic,
> but I just don’t know why I didn’t get one, perhaps some browser setting,
> dunno?!****
>
> ** **
>
> Greg ****
>
> _______________________________________________
> ozsilverlight mailing list
> ozsilverlight@ozsilverlight.com
> http://prdlxvm0001.codify.net/mailman/listinfo/ozsilverlight
>
>
_______________________________________________
ozsilverlight mailing list
ozsilverlight@ozsilverlight.com
http://prdlxvm0001.codify.net/mailman/listinfo/ozsilverlight

Reply via email to