Introduction

You have the several options for changing values of variables online:

  • In the shortcut menu for the variables

    • With the Change Value

    • With the command Set Value

    • With the command Force Value

  • In the menu Services

    • With the command Change Value

This applies to all elementary variables and elementary components of derived variables (DDTs and Arrays) with the following applications:

  • In LD (also see the Edge recognition chapter in the user guide).

    • Contact

    • Coil

    • Operation block

    • Comparison block

  • In FBD

    • FFB Pin

  • In SFC

    • Transition

  • In IL and ST

    • without limitation

NOTE: The above-named commands are only available in the Animation Mode.

Change value of variables

The Change value of variables dialog is modeless. This means that the dialog is not closed after modifying a variable. So you can modify several variables in a section.

One dialog is shown per section. Deactivating a section will hide the opened dialog. Closing a section or stopping the animation of a section will close the dialog.

Appearance:

Depending on the selected variables some functions of the dialog may be grayed out.

Elements:

Element

Description

Variable

The selected variable is displayed in this text box.

Every variable in a section can be selected either by means of this text box or by clicking on the variable in the section itself.

Value to be set

Enter the value to be set for the valuable in this text box.

When making the entry, ensure the correct syntax of the entered literal, e.g. 30s for a variable of data type TIME.

Use Set to assign the entered value to the selected variable and close the dialog.

Set to 0 or 1

This function is only available for Boolean variables.

Use to set the selected variable to 0 and close the dialog.

The same function is available with the command Set Value > Set to 0 in the context menu of the variable.

Use to set the selected variable to 1 and close the dialog.

The same function is available with the command Set Value > Set to 1 in the context menu of the variable.

Force / Cancel Force

This function is only available for located variables of data type EBOOL.

Also see the Edge recognition chapter in the user guide.

Use to force the selected variable to 0 and close the dialog. (The forced variable will be marked with a frame around the variable name.)

The same function is available with the command Force Value > Set to 0 in the context menu of the variable.

Use to force the selected variable to 1 and close the dialog. (The forced variable will be marked with a frame around the variable name.)

The same function is available with the command Set Value > Force to 1 in the context menu of the variable.

Use to cancel the Force command for the selected variable and close the dialog.

The same function is available with the command Set Value > Cancel Force in the context menu of the variable.