Distinguish uninstall from control panel VS upgrade - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

andreas.schuler
Posts: 1
Joined: Sat Mar 14, 2009 11:08 pm

Distinguish uninstall from control panel VS upgrade

Hi,

I was wondering whether it is possible to distinguish those two cases (while being uninstalled)
- User selects to remove app from control panel
- User updates app, which uninstalls the old one

During the uninstallation of the old app I would like to perform additional cleanup (config files etc.) if the user selected to remove it through the control panel. I want to preserve that data however if the user is upgrading.

Is there any way to determine this?

Thanks,

Andreas
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: Distinguish uninstall from control panel VS upgrade

Hi Andreas,

During an upgrade the property UPGRADINGPRODUCTCODE will be set in the package which is being uninstalled. Therefore, the condition for a complete uninstall would be:

Code: Select all

(REMOVE = "ALL") AND (NOT UPGRADINGPRODUCTCODE)
Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”