_IF IF x < 0 THEN i [...] ; FOR i := 0 TO 5 DO [...] 一次执行循环开始时为 0。条件 i <= 5 适用
:=0 TO 10 DO //OK i [...] ; END_FOR FOR i:=0 TO [...] ; END_FOR FOR i:=0 TO
_GLOBAL g_xVar AT %QX0.0 : BOOL ; g_iTest AT %QW0 : INT ; END
PROGRAM Test VAR_TEMP i [...] [0..10] OF INT; END_VAR FOR i
_GLOBAL g_xVar AT %QX0.0 : BOOL ; g_iTest AT [...] prog1 VAR i
_GLOBAL g_xGlob AT %QX0.0 : BOOL ; g_iGlob AT [...] ; END_VAR VAR i
_Address_Type_PRG VAR iVar AT %QB0 [...] .: %QX1.0 END_VAR i [...] .: %QW0 xTest AT %QW
PROGRAM PLC_PRG VAR i [...] Test : ARRAY[0..10] OF INT [...] Test : POINTER TO INT; i : INT
:= 0; END_IF i [...] A := 0; END_IF i [...] -Za-z0-9] 定义
Val2 <> 0 THEN iVal1 := i [...] 可能被零除的代码位置 理由:除以 0 导致错误。应始终首先检查要除法的变量是否为 0。 重要性:高 例 48