Question

I have a Visual Studio Setup Project that is very basic except for one modification. I have two different libraries that I would like installed based on the user's selection. I added a checkbox screen and conditions to the files. They can install either component or both components. This all works fine.

Now for my requirement. Let's say that the user installed the MSI and selected only one component. Now, they need to install the second component from the same MSI. If they run the MSI again, I get the option to repair or remove. Repair will only fix the component that was installed originally. How can I give them the option to install the other components by showing the checkbox screen again?

If this functionality isn't available in a VS Setup Project, is there something else where it is? WiX perhaps?

Was it helpful?

Solution

I don't think VS Setup projects support this. Wix or MSI's created from other tools like Installshield can support this. The usual way to handle this would be to create separate features and assign the different components to each feature. Then if the MSI is built using WiX or some other tool, from add/remove there will be the Change button/option through which you can get the option to repair, modify, or uninstall. Modify then lets you change your feature selections without doing a reinstall.

OTHER TIPS

You need to use the free MSI editors like ORCA or SuperORCA. Microsoft use to provide ORCA tool in their service pack. Not sure if they are continuing so. SuperORCA tool you can find at http://www.pantaray.com/msi_super_orca.html. Now when I had similar task to achieve following was my approach. I used SuperOrca to open my MSI file. 1] On repair/remove MSI dialog screen, add one more radiobutton for "Modify" - In SuperOrca-->Under RadioButton table --> Add entry for Modify radiobutton

2] Rename BackButton's text to "Reinstall" from its original "Back" --> In SuperOrca-->under Control table --> change Text property to rename Back to Reinstall

3] On selection of Repair/Remove radio button enable Finish button and disable Reinstall button. On select of modify radio button enable Reinstall button and disable Finish button - In SuperOrca--> Under ControlCondition table --> add entries for enable/disable "Reinstall" and "Finish" buttons for each comibinations for repair/remove screen (In my case dialog form name is "MaintananceForm")

4] Now from SuperOrca tools ControlEvent table find out conrol name for BackButton, In my case it is "PreviousButton". Now modify its Event, Argument & Condition entries from the table. And the values for these properties must be the same for the "Next" button properties from the Welcome screen of MSI file which redirects user to show installation options to choose.

Note: This is working fine for me. But when you re-select installation options again and click Next, somehow it does not forced for installing the selected option. Instead it repairs the MSI. I tried deleting entries from Windows\Installer folder so that MSI will not pick cashed installed version but no luck. If anybody is having answer on how to forced MSI to re-install through MSI setup wizard please let me know.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top