Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA™ InTouch HMI

Use local variables

  • Last UpdatedJul 23, 2024
  • 1 minute read

You can declare local variables in a script to store temporary or intermediate results. This increases performance and helps to keep your tag count low. You can use local variables just like tagnames in your script. However, there are certain differences:

  • Local variables only exist within the scope of the script in which they are declared. They lose their value when script execution finishes. They cannot be referenced by any other scripts in your application.

  • Local variables do not have dotfields.

  • Local variables do not count towards the tag count.

Before you can use a local variable in a script, you must declare it; otherwise, the reference is considered a tagname. See Declare a local variable.

You can declare local variables that have the same names as tags. See Naming conflicts between local variables and tags.

TitleResults for “How to create a CRG?”Also Available in