[00:00]
In this lesson, I'll demonstrate how to set up tag bindings so the values can be written back to tags. When manually setting up a tag binding, the default behavior will be that the property's updated when the tag updates, but not the other way around. In order to make the tag update when the property updates, we need to make the binding bidirectional. If I were to drag and drop one of my tags onto a window and create a control component, the bindings would automatically be set up for me. So I can go into preview mode, click the button, and see the tag value update. If I manually set up a tag binding, let's say on a spinner and change the spinner value, the tag won't update. To understand why, I can go into the binding on the two-state toggle and see that this bidirectional box has been checked. This is what controls whether the operator can write back to a tag.
[01:05]
I'll go back and open up the spinner binding and check that box, and now if I go in a preview mode and update the spinner, the tag value updates as well. If you notice while the tag write is happening, there are some dashed lines that appear around the component. This is a write pending overlay that lets us know that a tag write is occurring. It's a nice visual indicator that this component is writing to a tag. Again, if you wanna have a tag binding that also writes back to a tag, make sure that the bidirectional box is checked in the binding window.