cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
anom217
Level 8

Silent Uninstall needs password

I have a Basic MSI project and I want the user to be able to uninstall the application from Add/Remove Programs. I know this method only performs the Execute sequence to silently uninstall the app. My dilemma is, I need to uninstall some database stuff and need the user to enter the password to access it. For security reasons, I can't store this password anywhere. Is there any way for me to gather user input when removing software through ARP?
Labels (1)
0 Kudos
(3) Replies
MichaelU
Level 12 Flexeran
Level 12 Flexeran

There is no sanctioned way to put up UI during the ARP Uninstall (which runs a silent install). Custom actions can do it, but you run the risk of hanging the uninstall in scenarios where there is not a user around to fill in the UI. Generally the recommendation is to fail if the password is not specified, disable the Remove button, and require a UI-based uninstall -- that is unless the password's property is passed to the uninstall from the command line (something like: msiexec /qn /x {prod-uct-code-here} PASSWORD="ThePass").
0 Kudos
anom217
Level 8

It seems I could change the UninstallString registry value to launch a UI-based uninstall. However, I'd also need to change the WindowsInstaller value from it's default value of 1 for this to work. What exactly does the WindowsInstaller value do, aside from always calling the Remove as "msiexec /x{productcodeguid}"? Is it safe to edit the WindowsInstaller registry value?
0 Kudos
MichaelU
Level 12 Flexeran
Level 12 Flexeran

I would not suggest such an approach. Who knows when Windows Installer might "helpfully repair" the value which you propose deleting. Again, the common approach is to specify ARPNOREMOVE which requires the user go through the Change or Modify button instead. A less common approach is to set ARPSYSTEMCOMPONENT and create an entirely separate ARP entry which you control fully.
0 Kudos