Monday, April 15, 2019

How do I keep Visual Studio 2019 Preview for breaking on one exception at one line of code in particular?

There isn't a good way to do this. The compromise is to make that exception a different type of exception than the others. This touches on the ApplicationException in the root System namespace and suggests it's a long abandoned archaic thing and for my purposes it seemed like a fine outlier. The first time Visual Studio 2019 Preview breaks at this exception, there will be a little dialog box that appears in Debugging that has an "Exception Settings" subregion that you may expand to find a "Break when this exception type is user-unhandled" checkbox to check and that should solve your problems. I noticed that when adal.js tries to authenticate at a new browser tab for the first spin up that there is at least one attempt always when the username is just null. I both want to throw an exception instead of letting code go forward and I want to not stop Visual Studio 2019 Preview every time that happens. What else can I do?

No comments:

Post a Comment