# Set A Tag Value Using a Button

**URL:** <https://forum.inductiveautomation.com/t/set-a-tag-value-using-a-button/14987>\
**Category:** Ignition\
**Created:** [August 4, 2017, 4:58pm UTC](https://forum.inductiveautomation.com/t/set-a-tag-value-using-a-button/14987 "2017-08-04T16:58:58Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![slanglois](https://avatars.discourse-cdn.com/v4/letter/s/e47774/32.png) [@slanglois](https://forum.inductiveautomation.com/u/slanglois)\
**Post date:** [August 4, 2017, 4:58pm UTC](https://forum.inductiveautomation.com/t/set-a-tag-value-using-a-button/14987/1 "2017-08-04T16:58:58Z")

</div>

Hi, I’m pretty new to Ignition and I am looking for a way I could set a tag value from a component using a button.  
I have a custom property which call the base tag path and for the component on my page I use this property to bind it to a tag using indirect tag binding. Now I wish I could use a button to take that component value and set it to another tag using indirect binding.

---

<div class="post-metadata">

**Author:** ![hcarroll](https://avatars.discourse-cdn.com/v4/letter/h/e47c2d/32.png) [@hcarroll](https://forum.inductiveautomation.com/u/hcarroll)\
**Post date:** [August 4, 2017, 5:01pm UTC](https://forum.inductiveautomation.com/t/set-a-tag-value-using-a-button/14987/2 "2017-08-04T17:01:24Z")

</div>

You can use system.tag.write(tagpath, value) to write to another tag. You can get the property in the tree view.

---

<div class="post-metadata">

**Author:** ![slanglois](https://avatars.discourse-cdn.com/v4/letter/s/e47774/32.png) [@slanglois](https://forum.inductiveautomation.com/u/slanglois)\
**Post date:** [August 4, 2017, 5:08pm UTC](https://forum.inductiveautomation.com/t/set-a-tag-value-using-a-button/14987/3 "2017-08-04T17:08:24Z")

</div>

The problem is that my custom Property doesn’t hold the whole tag path just the prefix so I would need to add to it the rest of the tag path and that is what I don’t know how to do I’ve tried many different syntax but can’t find what’s going wrong

---

<div class="post-metadata">

**Author:** ![MMaynard](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mmaynard/32/3366_2.png) [@MMaynard](https://forum.inductiveautomation.com/u/MMaynard)\
**Post date:** [August 4, 2017, 6:44pm UTC](https://forum.inductiveautomation.com/t/set-a-tag-value-using-a-button/14987/4 "2017-08-04T18:44:20Z")

</div>

If you could post what you have it would help but basically

> tag="StringPartOfTagPath"+BoundTagPart  
> val = valueToWrite

> system.tag.write(tag,val)
