I am using VisualStudio2005 and a vdproj to create a simple MSI file. I need to pass in the REINSTALLMODE property when I launch it.
I know this can be done via command line, like so:
msiexec.exe /i foo.msi REINSTALLMODE=amus
However, if a user chooses to click the msi directly (launching the wizard), the property is not passed. Is it possible to do this via the VS and vdproj?
Some options I've investigated:
- When I build the MSI via VS, it also produces a setup.exe. Is there a way to pass the REINSTALLMODE property through this maybe?
- I installed Orca, which allows me to view/edit the Property table of the MSI. I could add it this way, but then I'd have to add it every time I do an MSI build.
Thanks for any advice.
I found a more automated way to do this.
Create a script named add_reinstall_prop.vbs(example) with the folowing:
Add a post-build event to your setup project calling the script with the following:
This will automatically add the desired entry to the built MSI. You can then check it with Orca to see the entry is now added automatically after build.
Sadly, I can't find a way to set other MSI properties right in VStudio.
Nonetheless, one method that should work is this: