# Dynamic binding tag to template custom property

**URL:** <https://forum.inductiveautomation.com/t/dynamic-binding-tag-to-template-custom-property/87783>\
**Category:** Ignition\
**Tags:** vision\
**Created:** [March 22, 2024, 11:07pm UTC](https://forum.inductiveautomation.com/t/dynamic-binding-tag-to-template-custom-property/87783 "2024-03-22T23:07:45Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [March 22, 2024, 11:12pm UTC](https://forum.inductiveautomation.com/t/dynamic-binding-tag-to-template-custom-property/87783/2 "2024-03-22T23:12:00Z")

</div>

Make a custom property on the template for only the tag value, and then indirectly bind that to your target tag. ~~Then, in another custom property, have your case statement inspect the value of the custom property that has the tag value. Pass the panel name and conveyor name into the template and use them for the indirect binding.~~ Man its a friday. 🙃

In a second property's binding, use an expression that uses `lookup` to look at a global dataset tag that has the colors/status numbers defined. Something along the lines of:

```python
lookup(
	{path.to.global.colors.tag},
	{this.custom.conveyorStatus},
	"black",
	"Status",
	"Color"
)

```

If you need to update colors, just adjust that global dataset.

> [@Wiki - how to post code on this forum](https://forum.inductiveautomation.com/t/wiki-how-to-post-code-on-this-forum/77831):
>
> This thread is intended as a short help file for all those struggling to post formatted code on the forum. Code block formatting Posting formatted code on the forum (and most others) is as simple as selecting the code and pressing the \</\> button. It works the same as applying Bold or Italic styles to your document. It preserves indentation and applies syntax highlighting. [How to post code] Note that all the \</\> button does is add three backticks ``` on the line before the code block and anot…

Browsing the [manual](https://www.docs.inductiveautomation.com/docs/8.1/ignition-modules/perspective/working-with-perspective-components/bindings-in-perspective/tag-bindings-in-perspective#indirect-tag-binding-mode) might help.

---

_[View the full topic](https://forum.inductiveautomation.com/t/dynamic-binding-tag-to-template-custom-property/87783)._
