In my console application, I have code that looks like
Process DKU = new Process(); DKU.StartInfo.FileName = "MSSQLExecutor.exe"; DKU.Start(); DKU.WaitForExit(); Console.WriteLine("lets move on ");
This works fine, and it waits for MSSQLExecutor.exe to complete its task, after which the application continues.
My problem is that sometimes MSSQLExecutor.exe crashes and Windows by default displays a dialog to end the program. At this point, my application will wait for the user to click the Close button.
I want to avoid this because MY application will work as a service without user interaction.

adopilot
source share