Document Properties: Triggers

On the Triggers tab, it is possible to set actions (including macro actions) to be invoked on document events, variable events and field events.

Not all actions can be invoked from the following event triggers.

Note:

There are limitations as to the behavior of certain macro triggers when working with documents on QlikView Server.

See: Using Macros in QV Documents on the QV-Server

Document Event Triggers In this group actions are set to trigger on selected events in the document. An event has to be selected in the list before it is possible to assign actions or macros to it.
OnAnySelect
Select this event to assign an action to be executed each time a selection has been made in any field of the QlikView document.
OnOpen
Select this event to assign an action to be executed each time the QlikView document is opened. This event is not supported when running in the AJAX client.
OnPostReduceData
Select this event to assign an action to be executed after each time the Reduce Data command has been executed.
OnPostReload
Select this event to assign an action to be executed each time the script has been re-executed.
Add Action(s)
This button opens the Actions page. On this page it is possible to add an action to the trigger. Choose the action macro to assign an existing macro name or type any name for which a macro can be created later in the Edit Module dialog.
The action will be executed each time the selected document event occurs. When an action has been assigned to the event, the button changes to Edit Action and it is possible to change the action for the event.
Field Event Triggers In this group actions are set to trigger on changes in the logical state of a specified field in the document. Select a field in the list and press one of the buttons to assign an action to in it. The buttons open the Actions page. Here it is possible to assign an action, including an existing macro name, or type any name for which a macro can be created later in the Edit Module dialog.
When an action has been assigned to the field, the button changes to Edit Action. The following Field Event Triggers exist:
OnSelect
The action will be executed each time a selection has been made in the specified field.
OnLock
The action will be executed each time the field is locked.
OnChange
The action will be executed each time a selection has been made in any field which is logically associated with the specified field.
OnUnlock
The action will be executed each time the field is unlocked.
Variable Event Triggers In this group you can set actions to trigger on changes in the contents of a specified variable in the document.
Select a variable in the list and press one of the buttons to assign an action to it. The buttons open the Actions page. On this page you can add an action to the trigger. Choose the action macro to assign an existing macro name or type any name for which you later can create a macro in the Edit Module dialog.
When an action has been assigned to the variable, the button changes to Edit Action and you can change the action for the event. The following Variable Event Triggers exist:
OnInput
The action will be executed each time a new value is directly entered in the selected variable.
OnChange
The action will be executed each time the value of the selected variable changes as a result of changes in other variables or the logical state of the document. This typically applies when the variable contains a formula.
Note: For backward compatibility to earlier versions of QlikView, the action must consist of a macro action. An action that consists of only one macro action is translated back to old string format on save.
Note: Actions that trigger other actions, so called cascading actions, may cause unforeseen consequences and are not supported!

Did this information help you?

Thanks for letting us know. Is there anything you'd like to tell us about this topic?

Can you tell us why it did not help you and how we can improve it?