Uninstaller questions - 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!

petre.balau
Posts: 2
Joined: Thu Jun 14, 2007 3:28 pm

Uninstaller questions

Hello,

I'm currently in the process of evaluating AI and so far I very pleased with it.
However, I have some questions related to the uninstall part.

My program generates some data files, which are supposed to stay if I'm upgrading and to go, if I'm uninstalling. Is there any way, using an Uninstall Custom action to check if this is actually an upgrade and not a regular uninstall?

How can I alter the Uninstall GUI? For the same reason as above, I want to insert a new dialog, with a checkbox on it, so the user can chose to remove/keep the data files.

Peter
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi Peter,

Thank you for your interest in Advanced Installer.

Here is an example on how this can be done:

Since those files are not created by the installer you need to create a custom action to remove them.

If you want to give to the user the option to remove or not those files on uninstall switch to "Dialogs" page and create a new CheckBox under "Maintenance->MaintenanceTypeDlg->VerifyRemoveDlg" dialog with following options:

Display Text: Keep the files.
Property Name: KEEP_PROP
Value: 1

Switch to "Custom Actions" page and create a custom action that remove the files under "InstallExecuteSequence->Uninstall" and use as "Execution Condition" following condition: (REMOVE="ALL" AND (NOT UPGRADINGPRODUCTCODE)) AND (NOT KEEP_PROP). With this condition the custom action will be executed on uninstall (not upgrade) and only if the CheckBox is not checked.

Hope this helps. Let me know if you encounter any problem.

Best Regards,
Gigi
______________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com
petre.balau
Posts: 2
Joined: Thu Jun 14, 2007 3:28 pm

Hello Gigi and thank you for the answer.

Your suggestion worked, but I still have some questions.

The modified dialog is used only when I chose "change" from CP->Add/Remove Programs. If I chose "Remove", there are no wizard dialogs, just deletes the program files (and keeps "mine" there). However, if I disable the "remove" button, the user will be forced to use the "Change" button and he/she will see the full uninstall wizard (which is fine). I noticed that Adobe Flash Player 9 entry in the "Add/Remove Programs" has just one button, "Change/Remove". Can I do the same with the current version of AI (5) ? If not, can this be pushed to the features list? :D


I wish you a nice weekend,

Petre
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi Petre,

As a suggestion you can change the default value of the check box in order to delete the files by default on uninstall.

However changing that text from "Add/Remove Programs" can be done by creating your own registry keys. If you want contact me on support at advancedinstaller dot com and i'll send you a test project.

Regards,
Gigi
______________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com

Return to “Common Problems”