Promotic

var - statement of language JavaScript

Description:
Declares variables.
Syntax:

var name [, ...];
var name [ = value [, ...]];

name Name of the variable
Note:
Variables declared with var in the procedure are available only within the procedure.

For similar purpose in the VBScript language is used the statement Dim and Set.

Using the new JavaScript statements of the Let and Const types is not recommended to use in the in the PROMOTIC system because the scripts must be functional also in the Web browser. These new statements may malfunction in older Web browsers.
Example:
Select and copy to clipboard

// Declare two variables
var nVar;
var nNum;

// Creation of two variables with assigned values
var nVar = 2;
var nNum = "text";
PROMOTIC 9.0.27 SCADA system documentation MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r.o.