[wix-users] How to pass the INSTALLFOLDER used to a program run as a custom action
Angus Comber
anguscomber at gmail.com
Sat Mar 7 07:48:00 PST 2020
I run a program, config_maker.exe, at the end of install but I need to know
the installation folder to write data to.
When I run the installer the current directory seems to
be C:\Windows\system32 , so I need to pass the instal path to the program.
I can do this on the command line. What syntax to use?
Here is my custom action:
<CustomAction Id="EXECUTE_AFTER_FINALIZE"
Execute="immediate"
Impersonate="yes"
Return="asyncNoWait"
FileKey="config_maker.exe"
ExeCommand="INSTALLFOLDER" />
I have a DirectoryRef for install folder like this:
<DirectoryRef Id="INSTALLFOLDER">
I get config_maker.exe print output to a known place and the argument is
printed like this:
arg=INSTALLFOLDER
So do I pass in a variable that will get substituted with the real value on
install?
More information about the wix-users
mailing list