Tag Value Changed Script Doesn't Run When Value Source is Reference To Another Tag (8.1.17)

I have a simple Memory tag, call it myMemTag. I has a simple value changed script that writes to another tag.

I have a simple Reference tag, call it myRefTag whose Value Source is myMemTag. The problem is the Value Changed script I have for myRefTag doesn’t execute. Is this by design…scripts on a Reference tag aren’t supposed to work?

Thanks,
Ted.

Just to be clear, you have the scrips inside Gateway Event Scripts | Tag Change?

No, not gateway, a Tag script.
Doesn’t matter though, I found the problem…I had a lot of white space (empty lines) in the script and a lot of comments. I deleted all of it and it works now. Weird.
@Transistor , thanks for asking.

1 Like

Still odd and weird in 8.1.27. Doesn't like comments in certain places. Deleting descriptive comments seems to be the work around.

How did you define your comments?

# or """

Both produce the same result.