I have a script that works in 7.9 to write a new value into the EngUnit for a tag based on a boolean value.
When running it in 8.0 it won’t change the value for me. I ran the script in the script console to check and got this error.
Has something changed for writing to a tag property?
What scripting function are you using? That looks more like an error indicating you’re not passing arguments into system.tag.write[blocking, async] correctly.
It’s important to know which function you’re calling because some of them expect a list of tag paths and values, and the error you’re getting seems to indicate you’re calling one that expects a list but only providing a single value.
Exactly what happens when it doesn’t work? Is it the original error? Also, where is this script being run? Such as tag event script, gateway timer script, etc. I tried on a 8.0.4 nightly build with success, so knowing your exact Ignition version would help too.
Yeah, I can’t replicate any problems here with a UDT and updating the engUnit tag property. If you can export the project window and the UDT tags, you can post them either here or send them to Support. From there, we should be able to figure it out pretty quickly.
The function works with memory tags. I tried even changing the engunits in the tag browser and it won’t work either. Is this a known problem.
I have attached the UDT to this. tags.json (89.3 KB)
Found a temporary fix for the issue.
The script will run ok when the override is ticked on the engunit in the instance.
Is this a bug? It worked without doing this in 7.9
This may have been fixed in the nightlies recently. As of today (8/23), I can write to a udt tag’s property and it will automatically create an override. My example worked with one udt instance but not a different one. I’ll have to keep digging.
I have also found that in 8.0 a property must already have an override before I can write to it. Rather than checking boxes manually, I have been setting those overrides up programmatically via system.tag.configure().