I'm working on an installer that drops some files into another application that keeps its files at [SystemDrive]\appName. The installer is only used in internal automation, so it's fine if it doesn't consider other install locations.
I've found that by default WiX sets the target directory to the drive with the most free space. What's the best way to specify a certain directory in the system drive instead?
Set the value of rootdrive to the drive you want
System drive will be by default the default drive used by OS
Added code to call 'SetRootDrive' action: You need to call it from InstallUISequence
MSI already gives you the value in the WindowsVolume property. Use that as the parent Directory/@Id.