Gateway Tag change script - change trigger

I have a gateway tag event that is looking at two opc tags and when they both go true I want my script to write to the database to run. Below are screenshot of both my tag event script and shared script

I went to my wrapper log on the gateway and realized that my print statements where writing twice which to me indicates that my event script is being called twice and I dont have the slightest idea on why.
unless its due to both tags being used as my change triggers

If both values change in the same OPC read cycle, it will indeed cause the script to be executed twice (both are true at that point).

A possible solution is to create an expression tag (the “and” of the two other tags), and react on that instead.

1 Like

I was hoping that putting it in the if statement would neglect that from happening, but I’ll go ahead and do that. Thank you very much.