cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
kellelein
Level 4

Trying to stop a service

I have an InstallShield msi project and it works ok. When I make an upgrade to the program, I would like to stop a service.

I can stop the service, but I get a warning message, where I have to select OK to proceed with the installation.

How do I get rid of this message? I just want the program to shut the service down and proceed.

Cheers

Kellelein
Labels (1)
0 Kudos
(4) Replies
J_anitha
Level 8

Use SystemFolder ^ "taskkill.exe" in LaunchAppAndWait() for stopping the service.
0 Kudos
Christoph
Level 8

with taskkill you kill a service, you don't stop it correctly.

You need to use the functions 'ServiceGetServiceState' and 'ServiceStopService'.

These functions shouldn't popup a dialog.
0 Kudos
Johannes_T
Level 6

I use LaunchApp with "net stop " for this purpose. Doesn't pop up anything.
0 Kudos
kellelein
Level 4

I currently call a script, who execute

ServiceStopService()
ServiceRemoveService()

This works fine, but I can't figure out, how to get rid of the message, when the user uninstalls the program 😞

How do I call the script, when the user uninstalls the program???

Now I insert the script in the Sequence -> Installation -> Execute. This works fine for install, but not for uninstall 😞

Kellelein
0 Kudos