Windows Service Update

I have a .exe written in .net (VB.net) 2.0. I install it as a service using instalutil.exe.

My question is: do I need to completely remove the service and reinstall it every time I do an update for exe?

I tried to stop the service and replace exe, but did not seem to reflect the changes made.

+4
source share
3 answers

If you stop the service, replace the executable file and restart the service, it will use the new executable file.

However, you need to make sure that the executable you are replacing is the one that is actually registered on the system.

+3
source

You can change the configuration programmatically using the ChangeServiceConfig API. I did it, it works. http://msdn.microsoft.com/en-us/library/ms681987%28v=vs.85%29.aspx

+2
source

This happens to me earlier, I delete the previous one to do a new job, so I think you really need to.

+1
source

Source: https://habr.com/ru/post/1344022/


All Articles