Service Start Type on Upgrade - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

PhilB
Posts: 95
Joined: Fri Jul 06, 2007 4:13 pm

Service Start Type on Upgrade

We have several products that are installed as services. For an initial install the Start type is deliberately set to On demand. When the user is happy that everything is OK they then set the service to be Automatic via the Service Control Manager. Subsequent releases of the product are installed as Major upgrades - which causes the service to be reset to on-demand. Is there any way to retain the existing service setting (i.e. automatic)?

Phil
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Service Start Type on Upgrade

Hi Phil,

For this you will need to implement a custom action that detects the state of the service. To make sure the custom actions runs only during an upgrade you can use the following
execution condition:

Code: Select all

NOT Installed AND OLDPRODUCTS
This custom action action must run after the standard action "FinRelatedProducts", before the old version is removed.

Then, at the end of the install process you can use another custom action, to start the service based on the settings detected and saved, into a property for example, by the first custom action.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”