HMI Web Display Builder Script for color change in HMI (Human Machine Interface) for Push Button


#1

IF ME.DataValue(“TAG1.MODE”) = 0 AND ME.DataValue(“TAG1.MODATTR”) = 0 THEN
ME.innerText = “MANL”
ME.fillColor = VBGREEN
ME.lineColor = VBGREEN
ELSEIF ME.DataValue(“TAG1.MODE”) = 0 AND ME.DataValue(“TAG1.MODATTR”) = 1 THEN
ME.innerText = “PROG”
ME.fillColor = VBYELLOW
ME.lineColor = VBYELLOW
ELSE
ME.innerText = “AUTO”
ME.fillColor = VBRED
ME.lineColor = VBRED

 END IF