Operator ‘NE’¶
This IEC operator is used for the “does not equal” function.
Permitted data types of the operands: any basic data type, depending on target system and compiler version: structure data type.
If the operands are not equal, then then the operator yields the result TRUE
; otherwise FALSE
.
If the target system supports the data type, then as from compiler version >= 3.5.7.0 also operands of type STRIUCT (structure) can be compared. Example: IF (stStruct1 := stStruct2) THEN...
.
Examples
Result in Var1
is FALSE
ST:
Var1 := 40 <> 40;
FBD: