Configuring Screens And Actions Groups
Screen and action groups can be configured on the "Installer->Screens & Actions" step.
Actions and screens can be grouped in the tree of installer elements. Groups of the same types can be nested, meaning that you can put a screen group into a screen group or an action group into an action group.
You can nest as many levels of groups as you wish. Next to the label of the screen or action group in the tree of installer elements the number of all contained screens or actions is shown in bold where elements in nested groups are counted as well.
Grouping offers the following benefits:
Organization
If you have many screens or actions, groups emphasize which elements belong together. You can add a common comment to the group.Common condition
Groups have a "Condition expression" property that allows you to skip the group with a common condition instead of having to repeat the condition for each contained element.Single link target
If you want to reuse a set of adjacent screens or actions in a different part of your project, you can put them in a group and add a single link to that group instead of linking to each element separately.Looping
A group has a "Loop expression" property that allows you to execute the group repeatedly until the loop expression returnsfalse
.Jump targets (screen groups only)
When you jump to a screen programmatically withcontext.gotoScreen(...)
, it is more maintainable to jump to a group instead of to a single screen. You can think of the group as a label in this case.
Properties of screen and action groups
The common properties of screen and action groups are:
Condition expression [Control Flow]
This expression is evaluated just before the screen is displayed. If the expression or script returnsfalse
, the entire screen group will be skipped.Loop [Control Flow]
If selected, the screen group will be looped. With the child properties you can set an expression that terminates the loop and configure a loop index that is available inside the loop.Note: If actions should be repeated in a loop, their "Can be executed multiple times" property has to be selected. If form components in a screen should be re-initialized on each loop, their "Reset initialization on previous" property has to be selected.
Loop expression [Configuration]
This expression is evaluated when the end of the screen group is reached. If it returnstrue
, all screens will be repeated. If you leave the expression empty, no loop will be performed.This property is only visible if "Loop" is selected.
Loop index start value [Configuration]
The start value for the loop index variable that is passed to the "Loop expression"This property is only visible if "Loop" is selected.
Loop index step [Configuration]
The step for the loop index variable that is passed to the "Loop expression". At the end of each loop, this step is added to the loop index. It is added before the "Loop expression" is evaluated. To decrement, specify a negative value.This property is only visible if "Loop" is selected.
Loop index variable name [Configuration]
If you want to use the loop index in a screen that is contained in the group, you can optionally save the value to an installer variable. Specify the variable name to which the value should be saved as ajava.lang.Integer
.This property is only visible if "Loop" is selected.
Style [GUI Options]
The default screen style for this installer application. Screens and screen groups can override this style.Action elevation type [Privileges]
If any contained actions should run in the elevated helper process, if their "Action elevation type" property is set to "Inherit from parent".An elevated helper process is available on Windows and macOS if the process has been started without admin privileges and the "Request privileges" action has been configured to require full privileges.
In addition, action groups have the following properties:
On error break group [Error Handling]
If selected, and one of the contained actions returns with an error, the control flow will step out of the action group and continue with the next element after the group. This behavior only takes effect if the problematic action has its failure strategy set to "Continue on failure".Error message [Configuration]
If the action group fails, this error message is displayed to the user. Otherwise, the action group fails silently.This property is only visible if "On error break group" is selected.
Failure strategy [Configuration]
The failure strategy that should be chosen if the action group fails. The "Error message" property will be used for the option dialog. If you also define a "Default error message", you will get two option dialogs, the first one from the action that causes the failure.This property is only visible if "On error break group" is selected.
Ask whether to ignore the failure [Configuration]
If an action fails, ask the user whether to ignore the failure and continue.This is one button in a message dialog that shows the error message and the available options to react to the failure.
This property is only visible if "Failure strategy" is set to "Ask user".
Ask whether to quit [Configuration]
If an action fails, ask the user whether to quit the installer application.This is one button in a message dialog that shows the error message and the available options to react to the failure.
This property is only visible if "Failure strategy" is set to "Ask user".
Ask whether to retry the action [Configuration]
If an action fails, ask the user whether to retry the action.This is one button in a message dialog that shows the error message and the available options to react to the failure.
This property is only visible if "Failure strategy" is set to "Ask user".
Retry expression [Configuration]
If this expression is set and returnstrue
, the action group is repeated. If the action group is configured to loop, the loop index will not be incremented.This property is only visible if "On error break group" is selected.
Default error message [Error Handling]
A default error message used by all actions that have no dedicated error message.