cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Highlighted
Occasional contributor

Uninstall tasks related question for InstallScript MSI project.

Hi all,
I have an InstallScript MSI project.
In the .rul files I want to do some install and uninstall tasks.

I do post install tasks in OnFirstUIAfter().

I want to do certain tasks at uninstall time. Where do I do that?
More specifically I want to call LaunchApplication during uninstall, both before the files are registry entries are remove and also after the files and registry entries are removed.

Is there an uninstall time equivalent of OnFirstUIAfter ? Or else where in the .rul file I can do this?

Appreciate any help.
Ash
Labels (1)
0 Kudos
2 Replies
Highlighted
Flexera beginner

Re: Uninstall tasks related question for InstallScript MSI project.

Ash,

I think the equivalent is OnMaintUIAfter. You can get to it by opening Setup.rul in your InstallScript editor; choose "After Move Data" from the first dropdown and "OnMaintUIAfter" for the second.

HTH
0 Kudos
Highlighted
Pilgrim

Re: Uninstall tasks related question for InstallScript MSI project.

ch_eng wrote:
Ash,

I think the equivalent is OnMaintUIAfter. You can get to it by opening Setup.rul in your InstallScript editor; choose "After Move Data" from the first dropdown and "OnMaintUIAfter" for the second.

HTH


Uninstall actions should occur during OnMaintUIBefore. Call your uninstall functions before the line FeatureRemoveAllInMediaAndLog(); which performs the uninstall actions and deletes the features.
If you put it after this there will be no files in the SUPPORTDIR folder. Or you could put the steps in the OnUninstall events for each of your features, which would be called by FeatureRemoveAllInMediaAndLog()

// The OnMaintUIBefore event is called by OnShowUI when the setup is
// running in maintenance mode. By default this event displays UI that
// allows the end user to add or remove features, repair currently
// installed features or uninstall the application.

Also consider adding a dialog option to the OnAbort event to display dialog and allow the option to uninstall files or perform cleanup tasks.
0 Kudos