Search code examples
c#wixinstallationwindows-installerwix-extension

Storing user-entered data from a Wix installer


I am creating a Wix installer and I would like to store some values that are set by the user during the installation process in such a way that I can read them at a later point in time. Obviously I could save these values in the registry but is there a better way to achieve this in Wix?


Solution

  • What's so wrong with storing them in the registry?

    Seriously :)

    I've been in the business for 20+ years and have seen the evolution from Windows 3.1 to Windows 8.1... going back further to Commodore 64 / 128D / CPM / AmigaOS but we won't count that. I saw the evolution from INI to Registry to XML and personally I think the hatred for the registry was overhyped. I do dislike COM and COM registration but using the HKLM and HKCU hives to store company / product specific configuration information is just fine and it's wonderfully supported by windows Installer. It's the XML support that Windows Installer lacks. To a degree, WiX lacks XML support also as the last time I looked it could write XML data but not read it without additional custom actions.

    So if you want a robust, solid installer, just use the registry.