Service restarts automatically after it is manually stopped
I have created a windows service in C#.NET that is continuously running. Now when i stop it from the services.msc initially i开发者_Go百科t shows that it has been stopped but after some time when i refresh the services.msc it shows as started again. I also checked in the task manager at the same time, i see that the exe of my application gets killed but starts on its own again.
Please help.
If you take a look into the properties of your service, there is a tab called Recovery. Maybe there is something configured on this page which automatically restarts the service.
Maybe you can use Process Monitor to find out a little more about who starts your service?
I suppose this was something to do with the operating system. I deployed my service on Win2k3 and it worked just fine. It started perfectly and stopped when i stopped it from Services.msc. I was trying to deploy the service on WinXP earlier. Please let me know if anyone else has faced such an issue.
精彩评论