I've tried:
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="ROOT_FOLDER" />
but ROOT_FOLDER
sometimes pointing to C: drive, sometimes to other drives, on different machines. How can I fix and tell it should be C drive root?
I've tried:
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="ROOT_FOLDER" />
but ROOT_FOLDER
sometimes pointing to C: drive, sometimes to other drives, on different machines. How can I fix and tell it should be C drive root?
There's a built-in Windows Installer property for this, it's called ROOTDRIVE. As you can see from its description:
...the installer sets ROOTDRIVE to the local drive that can be written to having the most free space.
If you always need it to be C, you can add a record to the Property table for this. In WiX, this is done like this:
<property id="ROOTDRIVE" value="C:\" />