Improper Use of Operand error in a Plain English Program.

Issue

A program turns on an output based on a comparison of a door's forced entry attribute and the value of a schedule numeric.  The program is disabling and throws an error.

Product Line

Andover Continuum

Environment

  • AC1
  • AC1 Plus
  • Plain English
  • CyberStation
  • Continuum

Cause

An Infinity Numeric and the Forced Entry attribute of a Continuum door object are incompatible value types. 

Resolution

Use an If/Then/Else expression to evaluate the value of the doors Forced Entry attribute, and the Infinity Numeric's value separately.  Then Switch the state of the output based on the result of the evaluation.

Original Code

  If (AHCASECACC100A ForcedEntry and PerimeterDoors) then Goto AlarmOutputOn

Corrected Code

  If (AHCASECACC100A ForcedEntry = True) and (PerimeterDoors = On) then Goto AlarmOutputOn