MSI Factory 2:
I'm having troubles setting the INSTALLDIR to the SourceDir. All I want to do is to set the INSTALLDIR to the directory where the .MSI (or .EXE) is run from. Anyone who can help. Thank you.
Professional Software Development Tools
MSI Factory 2:
I'm having troubles setting the INSTALLDIR to the SourceDir. All I want to do is to set the INSTALLDIR to the directory where the .MSI (or .EXE) is run from. Anyone who can help. Thank you.
Found the answer from Brent at Indigo Rose...
- Add a Set Folder custom action that sets INSTALLDIR to "C:\My Folder" (no quotes)
- In the attributes tab, set the scheduling to be Immediate - First Sequence
- Add two timing entries - one for InstallUISequence and one for InstallExecuteSequence - make them both happen After "CostFinalize" - also, use the condition "NOT Installed"
So far it seems to be working.
Well, it is not fixed. If I run my .MSI, the INSTALLDIR is set to where the .MSI is run from. But if I run my .EXE (need to bootstrap .NET), then the INSTALLDIR gets set to: C:\Users\Mike\AppData\Roaming\Downloaded Installations\{E86A2DC7-347D-409C-B3A1-BECD97B91889}\
So this must be where the .EXE extracts the .MSI to. Is there a way to transfer the SourceDir to the .MSI or maybe have it remeber where the .EXE is run from.