"What Happens If an Exception Isn’t Handled?" #114
-
Hi, Could you please write a complete example for "What Happens If an Exception Isn’t Handled?" ? I didn't understand well. Thank you |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
If an exception is not handled, the runtime gets a chance to deal with this. What happens is implementation defined. With a console application you'll see the application to stop and to show the exception. Unhandled exceptions from a BackgroundService Does this help? |
Beta Was this translation helpful? Give feedback.
If an exception is not handled, the runtime gets a chance to deal with this. What happens is implementation defined.
With a console application you'll see the application to stop and to show the exception.
With background services, there's a breaking change with .NET 6 to also stop the application - more information on this:
Unhandled exceptions from a BackgroundService
Does this help?