-

Defining Symbol Parameters and Adding Dynamics/Actions

When designing an HMI symbol, a dynamic/action which has been added to an object property inside the symbol, has to be made accessible from outside the symbol. This is done by linking the dynamic/action to a symbol parameter. In other words: when using an HMI symbol on an HMI page, a symbol parameter allows access to one particular dynamic/action inside the symbol.

Note
Public symbol parameters of symbol instances get their values during runtime based on the assigned variable (HMI tag). In contrast, the settings of non-published object/dynamic properties of symbol instances are static. This means, the properties keep the values defined when designing the symbol.

  1. First add a symbol parameter as follows:

    1. Open the 'Parameters' editor by clicking the editor name under the symbol page tab, if it is not already open.
    2. In the 'Parameters' editor, select the 'Enter parameter name here' cell and type the desired parameter name (max length: 50 characters; blanks are not allowed). Complete the entry by pressing <Enter> or <Tab>. If the entered name is not unique, a red cell frame is shown.
      Alternatively, click the toolbar button. This adds a new row at the top of the table with a default name.
    3. Select the parameter 'Type' from the drop-down list.

      The following types are available for selection:

      TypeDescription
      Variable - ANY*
      Variable - BOOL
      Can be linked to dynamics/actions that will visualize or write an IEC variable. Make sure that the selected type matches the IEC variable data type that will be connected when using the symbol in an HMI page.

      Example: a parameter of the type 'Variable - BOOL' is only suitable for dynamics and actions that can be assigned to a Boolean IEC variable (for example, the 'Visibility' dynamic or the 'Toggle value' action).
      Variable - UDTAllows to use a User-Defined Data Type (UDT) as symbol parameter. The UDT to be linked to the symbol parameter can be selected from the 'UDT' column. The column provides all UDTs that are available in your project. This includes all UDTs predefined in the system and the UDTs declared in the data type worksheets of your project.
      PageCan be linked to page-relating actions such as 'Load page'.
      Support FileAllows to define a support file parameter that can be linked to an 'Action on Click - Execute command' action that opens an HMI support file.

      Note
      ANY_NUM vs. ANY_BIT parameter types
      For parameter types of 'Variable - ANY_NUM' arithmetic operations such as addition, multiplication, etc. are allowed (for example, multiplication of variable value to allow scaling of an object). ANY_NUM parameters cannot be used to create partial bit expressions.
      For parameter types of 'Variable - ANY_BIT' it is possible to create partial bit expressions, but no arithmetic expressions.
       
      For further details on using expressions, see the topic "Using Expressions for Object Animation".

    4. If desired, enter a comment into the 'Comment' cell (max length: 250 characters).
  2. Add a dynamic/action to the property of an object inside the symbol.

    1. On the symbol page, select the object for which you want to add a dynamic/action.
    2. Click the 'Dynamics' tab in the properties window.
    3. On the 'Dynamics' tab, click the 'New Dynamic' button at the top of the tab and select the desired dynamic or action from the selection list. The dynamic/action parameters are added to the properties window.

    Further Info
    For general information about dynamics and actions, see the topic "Adding Dynamics".

  3. Assign the newly added dynamic/action to the symbol parameter:

    On the 'Dynamics' tab of the newly added dynamic/action, open the selection list right side of the 'Variable' or 'Page' field. Select the symbol parameter you have created in step 1.

    If the symbol parameter does not appear in the list, its type is not suitable for the newly added dynamic/action. In this case, modify the parameter 'Type' in the 'Parameters' editor accordingly.