ST Code shortcut: sum/subtract
Good morning,
I tryed to use the shortcut in ST code
Var += 1;
that is equal to
Var := Var +1;
but it is not accepted; is there a syntax error or the shortcut is not allowed?
Good morning,
I tryed to use the shortcut in ST code
Var += 1;
that is equal to
Var := Var +1;
but it is not accepted; is there a syntax error or the shortcut is not allowed?
Comments
The "addition assignment" operator
+=
is not allowed in Structured Text, at least not in PLCnext Engineer, and (I think) is not required by the IEC 61131 standard.