cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
roger_hurst
Level 5

start service

In basic MSI project, I've included a InstallService component and it installs.
Is there an option I've missed to have it auto start, or do I need to do my own startservicestart()?

It seems it should start with StartServices sequence.

Thanks
Labels (1)
0 Kudos
(3) Replies
schmoli
Level 6

You also need to author a "Control NT Services" area.

it's under [Component] -> Advanced Settings -> Control NT Services.

right click, add a new service, name it, add a new event, and verify "Install Start" is set to Yes.

While you're at it, "Uninstall Stop" and "Uninstall Delete" are probably useful for you as well.
0 Kudos
roger_hurst
Level 5

The service that I want to start depends on assemblies that are also used by other parts of the project. I had created components that target the GAC for these assemblies, but I'm having difficulty synchronizing the sequence so these assemblies are installed when StartServices needs them.

It looks like "Assembly" under the service component's "Advanced Settings" is a solution, but it's unclear how to set the properties on Win32 Assembly panel. The documentation says "Typical entry" for name is "the assembly name". Does this include the path? How does installShield know where the assembly is located?
0 Kudos
Ron_Schaeffer
Level 6

If your installer delivers files to the GAC, and the service you want to start relies on those GAC files, you can't use the built-in ServiceControl support to start your service. You need to write a custom action which is executed after InstallFinalize.

I'm in the middle of going through the same issues: http://community.flexerasoftware.com/showthread.php?t=190847

Regards

PS. if using InstallScript ServiceStartService, the 'service name' is the internal name of the service, not the public name seen in the Service Control Manager.
0 Kudos