I’m using an rtflicence standard bootstrapper to install dotnet before my poject msi in a chain.
I noticed that there’s an ‘options’ button which displays an install location dialog and allows the user to change the default installation directory.
I need to either:
- Prevent this options button from being displayed, or
- Populate the install location with a default path, and pass this back to the installer should the user change it.
I read that it’s possible to pass Burn variables to msipackages from bootstrapper but I haven’t found any further details and would appreciate being pointed in the right direction.
Thanks
To go with option 1, you’d have to roll your own BootstrapperApplication and remove the options button from the menu.
Option two is significantly easier to implement. The bootstrapper uses a special Burn variable called
InstallFolderto get and set what is in the text block on that view, which you can assign inside theBundleelement.The constant
ProgramFilesFolderwill set the value of that text block when the program starts, and if the user browses to a different directory, it will be stored in that same variable. To pass it to the MSI, in your chain, you pass theInstallFolderusing theMsiPropertytag (INSTALLLOCATIONis the name of the property in your WiX project).