Adding Constants

You can instantiate constants in the block Editor. The constant can be created from scratch or created from an existing predefined constant.

This task shows you how to:


Before you begin: The Block Editor workbench should be opened.
Related Topics
Defining Constants

Add New Constant

You can create an new constant with the Add Constant command.

  1. Select Add Constant and then click on the blank page where you want to add the constant.

    The Constant Block Properties dialog box is displayed:

    Text Mode: You can fill directly the value of the new constant.

    Tree Mode: As the syntax of a structured constant can be complex, the commands Add Tuple and Add Structure available in this mode facilitate the creation of structured data.

  2. Fill the value of the constant.



  3. Click the Properties tab. You can change the default instance name of the constant block and define the label that will be visible in the Block editor: instance name or value of the constant.



  4. Click OK. The constant block is displayed in the blank page. The instance is added to the tree.



Add Predefined Constant

You can add a constant already defined in the logic tree.

  1. Create a predefined constant. For more details, see Defining Constants.

    1. Select Insert ... > Constants ... > Constant in the contextual menu of the block.
    2. In the Position dialog box, select Before. The Constant Properties dialog box is opened.
    3. Fill the name of the constant and enter a numerical value in the Expression cell.

    4. Click OK. The constant is available in the specification tree.

  2. Select the constant in the specification tree and click Add Constant .

  3. Click on the blank page where you want to add the constant.



  4. Double-click the block to review its properties. The dialog box Constant Properties is displayed. See Add New Constant for the details of the dialog box.