Please enable JavaScript to view this site.

Altova MobileTogether Designer

This is an advanced feature that enables you to specify, on each Placeholder Control, a set of actions to execute when the placeholder's control template is executed. This set of actions overrides the actions defined in the control template, and is triggered when any action event defined in the control template occurs. It is therefore possible to define a different set of overriding actions for each placeholder control. In this way a control template can be modified at the placeholder level, separately for each placeholder control. For example, if three placeholder controls use a single control template, and you want to modify the control template when it is instantiated by one of the three placeholder controls, then you can define a set of overriding actions on this particular placeholder control.

 

How to override control-template actions

On a Placeholder Control, you can define a set of actions that override the control actions defined in a control template. Do this as follows:

 

 

1.Select the Placeholder Control for which you want to modify control-template actions.

2.In the Styles & Properties Pane, go to the placeholder control's properties and click the Additional Options button of its Control Action property (screenshot below). Alternatively, right-click the placeholder control and, in the context menu that appears, select Template Control Event Overrides.

MTDCTControlAction

3.In the Actions window that appears, enter the set of actions you want in the Template Control Event pane (see screenshot below).

MTDCTOverridingActionSet

In the screenshot above, the placeholder control's actions have been modified by means of an If-Then-Else action, as follows:

 

If the language of the client device is English, then the control template is executed as usual. This is achieved by adding, to the Then branch, a Template Event Callback action (shown highlighted in the Actions pane at left in the screenshot above). This action simply instantiates the control template.

If the client language is not English, then a message box is displayed. The Message Box action is added to the Else branch.

 

In the event that the control template contains more than one control, you can select different actions for each control event by using conditional processing that tests the value of the $MT_ControlKind or $MT_ControlName variables.

 

© 2020 Altova GmbH