I have an installer authored in Wix. The installer UI allows the user to select some settings. For example there is a checkbox to enable https for the web services. The values of these settings are stored in the windows registry using Rob Mensching’s “Remember Property” pattern. They update config files using the WixUtilExtension XmlFile. Installing the application the first time works fine.
When the user runs the installer again (when the application is already installed) they are given the option of changing features via the MaintenanceTypeDlg. The user can add or remove features in the CustomizeDlg. Then the installer wizard allows the user to change settings (e.g. https web services). Feature changes work fine, but when the user changes a setting it is ignored (the config file and registry key is not updated). Presumably because the config file and registry key are already installed.
How can I get the installer to make setting changes (update config files and registry keys) when making feature changes? Or is this not the right thing to do with windows installer?
The XmlFile WixUtilExtension will only run in two scenarios. If the component it belongs to is being installed the xml entry will get modified, and when the component is being uninstalled the xml entry the modification will get removed.
During a maintenance installation, the xml entry is not touched because the component most likely has the properties State: Installed, Request: Local, and so Action: Null.
http://msdn.microsoft.com/en-us/library/windows/desktop/aa367858.aspx
The fix is “to set REINSTALL” as mentioned here:
http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/use-XmlFile-XmlConfig-in-maintenance-mode-td5520598.html
Try setting the property REINSTALL=ALL using the command line to see if that works.
If so, then I’m thinking it can be set dynamically if the user chooses to perform a maintenance installation.