Message: First Operand of __QueryInterface must be an interface reference or the instance of a function block
Possible error cause: Incorrect operands are passed to the operator __QueryInterface
.
Error correction: Pass an interface reference or the instance of a function block.
Example of the error:
PROGRAM PLC_PRG VAR a : INT; ITFref, ITFref2 : ITF; ITFref2 : ITF2; END_VAR __QueryInterface(a ,ITFref); INTERFACE ITF EXTENDS __SYSTEM.IQueryInterface INTERFACE ITF2 EXTENDS ITF --> C0234: First Operand of __QueryInterface must be an interface reference or the instance of a function block
Error correction:
Example: __QueryInterface(ITFref2, ITFref);