.NET Core Global exception handler in console application
问题 I'm porting an console application to .NET Core , and I'm trying to replace this line: AppDomain.CurrentDomain.UnhandledException += UnhandledException; After reading this, it seems there is no built-in way to do this. So my question: is the only way to replace this line surrounding my entire code with a try/catch ? By reading this, it seems like there is another way, namely by keep on using System.AppDomain , but I can't seem to find this class/method. My only guess was this library, but it