I want to write the value of a numeric label to a tag.
I usually use this script in the property change to write into a tag.
if event.propertyName == “intValue”:
value = event.source.intValue
system.tag.write(“Output1”, value)
Now I want to add a condition to write in a particular tag based on a selection like a dropdown list
as the value of the numeric label has a reference from the dropdown list.
Like if 1 is selected it will be for Output1
2 will be for Output2 …
While probably not what you need, this may be one to keep in mind for the future.
You can use the dropdown menu’s dataset to define the tagpath and tag value to write for each item in the drop down menu. For this to work, you would need to add another column/field to the drop down menu’s data property called “TagPath” and “Value”.