I have a windows service which has a number of threads that do some work. All has been going well in testing, until once, where I saw "windows service terminated unexpectedly" in the event viewer.
How do I go about trying to debug where this is happening? I have exceptions being caught under normal circumstances but not in this case.
I do not know where to start.
JD.
Put a call to System.Diagnostics.Debugger.Break() in your OnStart() callback. When your service starts up, you'll be prompted to start the Visual Studio debugger. Once the debugger opens, you can debug from there.
here you can find How to: Debug Windows Service Applications
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With