Amending MSI Package Dialogs - Resume and First Time Install - Advanced Installer Community
hitman
Posts: 6
Joined: Tue Jan 31, 2017 4:19 pm

Amending MSI Package Dialogs - Resume and First Time Install

The installer I've setup seems to use the "Resume" dialogs when uninstalling via Programs and Features. This works fine operationally, however all the dialogs refer to an installation rather than an uninstall which is a little confusing.

I've just amended the template so the Resume function refers to "Uninstall" and "Removing" rather than "Installing", however as the Resume dialogs use default entries such as PrepareDlg and ProgressDlg this affects the dialogs relating to the first time install.

I'd rather not have to create brand new dialogs purely for this, but I can't see a way to duplicate these dialogs and keep them independent.

Am I missing something?

Thanks!
Catalin
Posts: 7852
Joined: Wed Jun 13, 2018 7:49 am

Re: Amending MSI Package Dialogs - Resume and First Time Install

Hello,
The installer I've setup seems to use the "Resume" dialogs when uninstalling via Programs and Features. This works fine operationally, however all the dialogs refer to an installation rather than an uninstall which is a little confusing.
Indeed, you are right, the "Resume" dialogs are shown when an MSI installation is resumed after being interrupted. Some parts of the text from the respective dialogs (i.e. ProgressDlg) are controlled by some properties such as: [Wizard], [Progress2], [ProductName]. For instance, the text from the "ProgressDlg" is:

Please wait while the Setup Wizard installs Your Application. This may take several minutes.

where:

- The [Wizard] property stores the following value: "Setup Wizard"
- The [Progress2] property stores the following value: "installs"
- The [ProductName] property stores the following value: "Your Application"

What we want to control here is the "installs" text, which we want replaced with "uninstalls", so the confusion will no longer occur. To do so, you can proceed as it follows:

- Go to "Install Parameters" page and create a property which has the following value: "installs" (without quotes).

- Now go to "Dialogs" page --> select on the "ProgressDlg" dialog from under the "Resume" section. Now click on the text and, on the right pane, under "Properties" -> "Display" select "Text" and then click on the "..." button. In the "Edit Control Text" dialog, please modify the text by replacing the "[Progress2]" property with the earlier created property.

- Now, the last step is to modify the property's value during the uninstall process. To do so, please go to "Custom Actions" page and create a "SetProperty" custom action with sequence. To do so, simply press the "Add custom action with sequence" button which is placed to the right side of the custom action's name. The custom action should look like this:

Property: THE_EARLIER_CREATED_PROPERTY
Value: uninstalls
Execution Time: Immediately

Schedule it before the "Searches" action group from under the "Wizard Dialogs Stage" by simply dragging and dropping it.

Dialogs Stage Condition: Uninstall only (untick Install and Maintenance)

Hope this helps.

All the best,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”