Installing, Controlling, and Configuring Windows Services

InstallShield 2016

Project • This information applies to the following project types:

Basic MSI
DIM
InstallScript MSI
Merge Module
MSI Database
MSM Database
Transform

Windows services are executable files that Windows–based systems run in the background to manage various system tasks, even if no user is currently logged in. A service is an executable file, but it must be designed as a service; you cannot automatically use an arbitrary executable file as a service. Windows services can be installed to run every time that the system starts or on demand when needed. InstallShield enables you to install new Windows services and configure existing services. Windows has a Services administrative tool with which you can view and configure the services that are installed on a system.

You can use the Services view to configure a component that installs, starts, stops, or deletes a service during installation or uninstallation. You can also use this view to configure extended service customization options that are available with Windows Installer 5. As an alternative to using the Services view, you can use the Services area under the Advanced Settings node of the Components view or the Setup Design view. If you configure service information in any of these areas, the other areas are automatically updated accordingly.

Note the following details about working with services:

The service that you are starting, stopping, deleting, or configuring can either be already present on the target system during installation or uninstallation, or it can be installed as part of your installation.
The service executable file should be the key file of its component. For more information, see Component Key Files.
The Remote Installation setting for the service’s component must be set to Favor Local. For more information, see Setting a Component’s Remote Installation Setting.

Tip • The View Filter at the top of the Services view lets you select a component or feature whose service data you want to display in the view, and hide the ones whose service data you do not want to display in the view. The View Filter lists your project’s hierarchy of features, subfeatures, and components.

To install, start, stop, delete, uninstall, or configure a service:

1. If your installation is installing the service, add the service executable file to a component in your project, and make it the key file of the component. For more information, see Adding Files to Components.

If the service is already present on target systems, skip this step.

2. In the View List under System Configuration, click Services.
3. Right-click the Services node and then click Add Service. InstallShield adds a new service.
4. Type a new name for the service now, or click it and then press F2 later to rename it.

The name that you enter must match the name that is shown on the service’s Properties dialog box. (To access an installed service’s properties: In the Services administrative tool, right-click the service and then click Properties.)

5. Select the service that you added, and then configure the settings that are displayed in the right pane as needed. For information about each of the settings, see Services View.

Repeat the process for each service in this component’s key file.

Note • You must be familiar with the technical details of your service before you can configure its settings.

Tip • If configuring the service fails at run time, the installation may fail with an error message. ICE102 validates some of the service-related settings to help avoid such configuration failures. Therefore, it is recommended that you perform validation for your release.

See Also