In order to achieve this, you can use our predefined support for "DetectService"
custom action. To do so, please go to "Custom Actions" page and add a "DetectService" custom action with sequence
(simply press the "Add custom action with sequence"
button which is placed on the right side of the custom action's name).
Uncheck the "Uninstall" and "Maintenance" options from under the "Execution Stage Condition"
Please be careful not to use the service display name, but it's real name instead. To get a service name, please proceed as it follows:
- Open a "Run" window by pressing the Win+R buttons combination.
- Type: services.msc
- Look up for your service --> right click on it --> "Properties"
--> "Service name:"
The "DetectService" custom aciton initializes a property ([AI_SERVICE_STATE]
) with the following values:
- "Not Found"
Now we have to schedule it before the "Paths Resolution" action group --> "Wizard Dialogs Stage"
. To do so, simply drag and drop it before the specified action group.
Now that we have created the custom action, all we have to do is to create a custom launch condition based on that. To do so, please proceed as it follows:
- Go to "Launch Conditions"
page --> "Custom"
- Press "New..."
and in the "Condition"
field please insert the following condition:
(We only want to install our setup when the SQL is not installed --> the service is not found)
Hope this helps.