I tried to use script on LED display. What I want is to trigger script when tag value = 20.
So I have tank level tag. I have LED display to indicate stock level of full 100 liters drum for tanks, 5 at the moment. Every time full drum is replaced I want to deduct 1 unit from number 5 “stock level”.
In my case I want trigger the script when drum level reach 20 as this is minimum tank level when drums are replaced.
if “E-Coat/Test”.value ==20:
value = event.source.value
newvalue = value - 1
event.source.value = newvalue
Thanks for you help