Is it possible to have the Windows Service stop itself in case of an error Funny thing is that if there is an error OnStart then it throws an exception and stops. But if the error happens during the course of the run, it throws an exception to the EventLog and it keeps on running.
I do not want to manually stop it, I want the service to stop itself. Is that possible. End keyword works, but is there anything other than that
Thanks for your help.

Window Services question
Zeeshan Umar