We created an Expression tag (partCounter) with a valueChanged Tag Event that uses system.tag.write() to update a Memory tag (outfeedCounter) anytime partCounter changes. We then store the value of outfeedCounter Memory tag in a database.
Everything works fine until we open the Tag properties of outfeedCounter Memory tag and later hit OK or Apply. It appears the “value” property shows the most current value (at the time the tag editor is opened) and if we wait a few seconds, long enough for the Expression tag partCounter to change and hit OK or Apply, the “stale” value shown in the tag editor gets written to the outfeedCounter Memory Tag and causes issues when we store it in the database because it’s less than the current value.
Does anyone know how to get around this? We have played with initialChange but I think hitting OK or Apply causes the value in the Tag editor window to re-write the value on the tag after an initialChange event so it doesn’t help.