views:

44

answers:

1

Hello everyone,

We are using VS2008 native Installer to set up our product. During both installation and product removal, we use Custom Actions to ask the user if he would like to keep his existing DB and settings (if detected). The arises when the user is upgrading: the Installer starts, recognizes there is a previous version installed, and calls the UnInstaller first. So the user is thus presented with the same Q twice - once during the uninstall of the previous version, and again during installation of the first.

Is there some way to "let the uninstaller" know that it is being called as part of an upgrade, so we can bypass one of the questions?

+2  A: 

I'm not sure about the specifics of VS2008, but if you're generating an MSI package you can schedule display of the dialog based on the UPGRADINGPRODUCTCODE property - this is automatically set during an upgrade with the product code of the package that is being uninstalled.

sascha
Nailed it right on the head, thanks a lot!
Eran Rehavi