PDA

View Full Version : Custom actions on uninstall but not upgrade?



JMetcoff
08-01-2018, 09:47 AM
Does anyone know how to run a custom action on an uninstall but not on an upgrade? I need to delete data files. It seems like a very basic requirement. I believe it can be done in MSI, but doesn't appear to be in Express.

Jenifer
08-04-2018, 04:12 AM
Does anyone know how to run a custom action on an uninstall but not on an upgrade? I need to delete data files. It seems like a very basic requirement. I believe it can be done in MSI, but doesn't appear to be in Express.

Hi,

If your intention is to delete files,you can achieve it via AddFieRemoval option in Files and Folders view or directly adding file entries to RemoveFile table.While adding files you will can select when to delete files.Options are

1.Installation

2. Uninstallation

3.Both installation & uninstallation.

As per your need,you can opt for installation which includes upgrade.Refer this link for more details:
http://helpnet.installshield.com/installshield24helplib/helplibrary/IDlgRemoveFileProp_General.htm#ref-dialogboxesa-m_1989872897_1096438


Hope this helps,
Thanks,
Jenifer

JMetcoff
08-07-2018, 07:49 PM
Hi Jennifer,

Thanks for responding. Unfortunately, the file-remove action is deleting files on an upgrade. I only want to delete files if the user really wants to uninstall the product.

Basically, I think I need to use this MSI condition, but Installshield won't let me enter my own conditions:

REMOVE="ALL" AND NOT UPGRADINGPRODUCTCODE

Regards,

Jerry Metcoff
Gypsy BI LLC