hugi
27th February 2006 18:49 UTC
stop a service with nsSCM
Hello,
I have a problem with the nsSCM-Plugin.
I install my own service and than I start this service with following command:
nsSCM
::Start/NOUNLOAD"$dienstName"
In the next line I´d to check the status with following command:
nsSCM
::QueryStatus/NOUNLOAD"$dienstName"
It doesn´t work. When I does not use /NOUNLOAD in the Start-Commandline it works.
Why?
In the next section I try to stop the service. It returns error when I use the NOUNLOAD-Flag, it returns "success" when I don´t use the /NOUNLOAD-Flag but it don´t stop really.
Have anybody an idea?
Afrow UK
27th February 2006 19:02 UTC
Does nsSCM tell you specifically to use /NOUNLOAD?
-Stu
hugi
28th February 2006 11:10 UTC
Yes, it does.
http://nsis.sourceforge.net/Service_...s_on_NT/2K/XP)
/NOUNLOAD only effects, that the .dll is not deleted in the Plugins-Dir or not?
kichik
28th February 2006 18:39 UTC
/NOUNLOAD makes the installer not use FreeLibrary. According to its source code, /NOUNLOAD isn't really required. It'll just save a few operations like opening and closing the service database for each call. If it works without /NOUNLOAD, you can get rid of /NOUNLOAD.
hugi
2nd March 2006 12:13 UTC
Thank you for your help. Now it works!!!