Stop Visual Studio from breaking on exception in Tasks

Ok I found out how to do it. The answer is right here in the note section

When “Just My Code” is enabled, Visual Studio in some cases will break on the line that throws the exception and display an error message that says “exception not handled by user code.” This error is benign. You can press F5 to continue and see the exception-handling behavior that is demonstrated in these examples. To prevent Visual Studio from breaking on the first error, just uncheck the Enable Just My Code checkbox under Tools, Options, Debugging, General.

Leave a Comment