We'll have a look at how to write try and catch statements, how to add multiple catch statements and how to write custom exceptions.
Afterwards, we'll go through a number of different scenarios to see whether the catch and finally code blocks run in an ASP.NET Core Web API and a Console application.
► Read the tutorial:
https://www.roundthecode.com/dotnet-t...
🎓 .NET tutorials, code examples and coding challenges 🎓
https://www.roundthecode.com/?utm_sou...
► Chapters
0:00 Coming up...
0:11 Purpose of a try/catch block
1:48 Different exception classes
4:45 When the try, catch and finally code blocks run
7:42 Conclusion
8:09 Exception handling middleware in ASP.NET Core