# Tag Change Script Store Annotations

**URL:** <https://forum.inductiveautomation.com/t/tag-change-script-store-annotations/64776>\
**Category:** Ignition\
**Tags:** scripting, perspective\
**Created:** [October 3, 2022, 9:13pm UTC](https://forum.inductiveautomation.com/t/tag-change-script-store-annotations/64776 "2022-10-03T21:13:09Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Brad\_Medley](https://avatars.discourse-cdn.com/v4/letter/b/82dd89/32.png) [@Brad\_Medley](https://forum.inductiveautomation.com/u/Brad_Medley)\
**Post date:** [October 3, 2022, 9:13pm UTC](https://forum.inductiveautomation.com/t/tag-change-script-store-annotations/64776/1 "2022-10-03T21:13:09Z")

</div>

I am looking to automatically store an annotation through tag script on value change, but I am not having success. Currently I am just using a Boolean value to test the script out.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/e/4/e4453a1a78c4bf5d6f2ebc2e42c925afb863666b.png)

When I perform the scripting through the script console it does place the annotation in the annotation table.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/f/2/f26cc03b1c5681a3ae17bd563b91c681bd72ee67.png)

Any advice on how to get this to work with value change.

---

<div class="post-metadata">

**Author:** ![Brad\_Medley](https://avatars.discourse-cdn.com/v4/letter/b/82dd89/32.png) [@Brad\_Medley](https://forum.inductiveautomation.com/u/Brad_Medley)\
**Post date:** [October 3, 2022, 9:23pm UTC](https://forum.inductiveautomation.com/t/tag-change-script-store-annotations/64776/2 "2022-10-03T21:23:46Z")

</div>

I think I answered my own question. It looks like in Tag Scripting it needed to be indented while script console did not.

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [October 3, 2022, 9:27pm UTC](https://forum.inductiveautomation.com/t/tag-change-script-store-annotations/64776/3 "2022-10-03T21:27:30Z")

</div>

Yes. the colon at the end of the `def` line is a clue to the start of a section. An outdent back to column 0 signals the end of the function and Python requires at least one line inside a function.
