Scripting - System.tag.configure - dataType: Document

I’m on 8.1.5

I want to use an UDT with a memory tag dataType Document, and I search the best pratice to update the value with the system.tag.configure.

I want to be able to add and modify object in the document.

You don’t use system.tag.configure. Just normal writes. The key is that you will need to write the complete document after you make changes.

The thing is that I want to update the UDT, not the instance tag

This kind of defeats the purpose of a UDT... If all UDT instances should have the same document value, you should just create a single standard tag (or other) and set the value once there. Editing the definition of a UDT to change the value of a tag within to effect a change in its instances doesn't make any sense. As soon as you write to that tag in the instance, the value is overridden and it loses its link to the UDT definition's value.

I use a specific tag in the UDT to store some configuration info, that tag is readonly for the client. I finally found a way to do what I expected.