[wix-users] Problem Updating

Jon Earle earlej at hotmail.com
Tue Mar 6 08:22:15 PST 2018


Right... during Install, REMOVE is definitely not ALL.  That's fine and what I want.  However, during Uninstall, REMOVE would be set to ALL, yet the component continues to be applied.

I  tried setting the Start to just "install" and it does not start the service...

Here is my flow:

  1.  Install the MSI with all features selected.
  2.  De-select the PCI component and click Modify (to remove it).
  3.  Select the PCI component and click Modify (to add it).
  4.  Click Uninstall.

Results:

  1.  App is installed, with all features, drivers and services. Services are started.
  2.  Services are stopped. PCI feature and drivers are removed. Services are not restarted -- PROBLEM.
  3.  Services are stopped (already were). PCI feature and drivers are installed. Services are started.
  4.  Entire app, incl all features, drivers and services, is removed.

With the condition set to NOT REMOVE~="ALL" and the service controls set to Start = Stop = "both", the services are stopped and restarted in steps 2 and 3, which is correct, however, the services are also started during Uninstall, which is not correct.

If the Condition does not help in this case, I'll yank it out.  How then, would I author the control to stop and start the services only when Modifying and not Uninstalling?  Custom Action?  Didn't want to go there if there is a "Wix" way.

Cheers!
Jon




________________________________
From: Nir Bar <nir.bar at panel-sw.com>
Sent: Tuesday, March 6, 2018 3:11 AM
To: Jon Earle
Cc: Hoover, Jacob; Jon Earle via wix-users
Subject: Re: [wix-users] Problem Updating

Component condition just says whether or not the component is to be installed.
So setting it to 'NOT REMOVE="ALL"' will always evaluate to true since during install REMOVE is definitely not "ALL".

Setting ServiceControl Start="both" is odd since it means you want to start the service during uninstall. This is required only when you're stopping services that are not part of your MSI (such as IIS).

I think you only need to change Start="install" and remove the condition altogether.

--
Nir Bar, Independent WiX Expert. Creator of-
JetBA: WiX WPF Bootstrapper User Interface Framework
JetBA++: WiX Native Bootstrapper User Interface Framework





More information about the wix-users mailing list