Stop Visual Studio from breaking on exception in Tasks

前端 未结 3 544
闹比i
闹比i 2020-12-06 00:34

I have the following code:

Task load = Task.Factory.StartNew(() => {//Some Stuff Which Throws an Exception});

try
{
    load.Wait();
}
catch (AggregateExc         


        
3条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-06 01:08

    To turn off stop on exceptions press " Ctrl + Alt + E ". This will open the Exceptions window . Untick "Common Language Runtime Exceptions - Thrown".

提交回复
热议问题