catsaremyfriends
Posts: 33
Joined: Thu Mar 26, 2009 9:21 pm

How can Rollback custom action occur"Before Initialization"?

In Custom Actions, the tool displays under InstallExecuteSequence:
Uninstall
Rollback
Install
Commit

I presume that these indicate separate phases that occur while the install occurs and that they occur in a sequence like:
Install
Commit
Rollback
Uninstall


I would also presume that when I select one of these, and I add a Standard Action that the tool would only allow me to define an action that can occur in that phase. This does not seem to be the case. For example, if I select Rollback the standard action list drops down with the choice Before Initialization from where I could select something like InstallValidate

This does not make a lot of sense to me because presumably anything that is done during a rollback would occur a long time after install validation has occured. Similarily, being able to select Before Initialization under Rollback makes no sense either.

Am I missing something here in my understanding of how this works?

Thanks,

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

Re: How can Rollback custom action occur"Before Initialization"?

Hi,

Please note that the Custom Actions page is designed for actions you want to execute during an install or uninstall, but are not supported by Advanced Installer or Windows Installer. Also, the entries visible in this page are predefined standard actions under which you can schedule a custom action (for example, launch an EXE after the "Install" standard action runs). You can find a complete list of the available standard actions here.

Under the "Rollback" standard action you can add custom actions you want to run during installation rollback. All standard actions will be included in an install or uninstall process. However, based on the configuration of the package and the install process (install or uninstall), only some of them will run.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
catsaremyfriends
Posts: 33
Joined: Thu Mar 26, 2009 9:21 pm

Re: How can Rollback custom action occur"Before Initialization"?

Hi:
OK this is still a little confusing to me. First I have some clarifying questions and a couple of comments...

The User Guide talks about "two main branches which correspond to the two main installation phases"

Does this mean: InstallUISequence & InstallExecuteSequence?

The User Guide talks about "a scondary branch which represents the custom actions"

Does this mean: Uninstall, Rollback, Install & Commit?

The User Guide says: "for each of these you can show more branches in which you can add custom actions using the [ Show Standard Action] Toolbar button"

So, would "more branches" mean: Before Initialization, Before File Installation, Before Finalization?

Assuming "yes" to the above answers, then I interpret the Guide as follows:

You can attach a custom action to a standard action which is associated with the Before Initialization branch
of the Rollback branch of the InstallExecuteSequence branch.

However, based upon what I observe, I think the tool works like this...
You can associate a custom action with one of the Standard windows installer actions. These are available via the
Show Standard Action button on the toolbar.

-- AND / OR --

You can associate a custom action with one of the four branches under InstallExecuteSequence using
either of the buttons New Attached Custom Action, New Installed Custom Action or New Custom Action
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: How can Rollback custom action occur"Before Initialization"?

Hi,
The User Guide talks about "two main branches which correspond to the two main installation phases"
Does this mean: InstallUISequence & InstallExecuteSequence?
Yes. During "InstallUISequence" the installation dialogs are shown and during "InstallExecuteSequence" the actual install is performed.
The User Guide talks about "a scondary branch which represents the custom actions"
Does this mean: Uninstall, Rollback, Install & Commit?
No, this refers to "UI Custom Actions" branch which is available in an Enterprise project. Please note that the actual text in the User Guide is:
"a secondary branch which represents the custom actions which can be used by DoAction control events on the dialogs of the installation"
Basically, the UI custom actions can be used by DoAction control events on the installation dialogs. This allows you to run a custom action when a button is pushed.
The User Guide says: "for each of these you can show more branches in which you can add custom actions using the [ Show Standard Action] Toolbar button"
So, would "more branches" mean: Before Initialization, Before File Installation, Before Finalization?
No, this refers to the standard actions you can add. "Before Initialization", "Before File Installation" and "Before Finalization" are simply categories for the standard actions.
Assuming "yes" to the above answers, then I interpret the Guide as follows:

You can attach a custom action to a standard action which is associated with the Before Initialization branch
of the Rollback branch of the InstallExecuteSequence branch.

However, based upon what I observe, I think the tool works like this...
You can associate a custom action with one of the Standard windows installer actions. These are available via the
Show Standard Action button on the toolbar.

-- AND / OR --

You can associate a custom action with one of the four branches under InstallExecuteSequence using
either of the buttons New Attached Custom Action, New Installed Custom Action or New Custom Action
The installation process works like this:
- when InstallUISequence runs, it shows the installation dialogs and it executes its standard actions you can show through "Show Standard Action" toolbar button or context menu
- when InstallExecuteSequence runs, some of its standard actions (you can show them through "Show Standard Action" toolbar button or context menu) are executed based on their conditions

So basically, the installer uses two sequences which run standard actions. After one of these standard actions you can add one or more custom actions. Please note that "Uninstall", "Rollback", "Install" and "Commit" are also standard actions (you can add custom actions after them).

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”