AssertFalse

The AssertFalse method can be used to check whether the condition evaluated in the application code is FALSE. If this is not the case, a corresponding error message can be passed via the sMessage parameter.
Syntax
METHOD PUBLIC AssertFalse
VAR_INPUT
bCondition : BOOL
sMessage : STRING
END_VAR
Inputs
|
Name |
Type |
Description |
|---|---|---|
|
bCondition |
BOOL |
A BOOL value that is evaluated according to the method. |
|
sMessage |
STRING(255) |
Error message to be passed |
Sample
AssertFalse(bCondition:=<condition>,sMessage:='Error message to be displayed in the client!');