Exceptions being thrown deep in the bowels of White

Apr 27, 2009 at 2:55 PM
If you have a Button that closes a form when clicked then an exception is thrown.

Now, admittedly, you only see that exception if you have VS configured to catch _all_ exceptions, rather than just unhandled ones, but it would still be nice if there weren't exceptions being thrown and caught like that.

Any way to avoid it?  Or is it an integral problem to the UIAutomation API it's based on?
Apr 27, 2009 at 3:37 PM
Aha!  If it can't be avoided then a [DebuggerNonUserCode] attribute can be applied to the methods that throw/catch the exception and Visual Studio will ignore them.
May 8, 2009 at 9:34 AM

I'm an idiot.  I meant [DebuggerHidden].

May 8, 2009 at 2:04 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.