# Is it possible to call a script when tag value changed in 8.0.1

**URL:** <https://forum.inductiveautomation.com/t/is-it-possible-to-call-a-script-when-tag-value-changed-in-8-0-1/25381>\
**Category:** Ignition\
**Tags:** ignition80\
**Created:** [May 29, 2019, 1:53am UTC](https://forum.inductiveautomation.com/t/is-it-possible-to-call-a-script-when-tag-value-changed-in-8-0-1/25381 "2019-05-29T01:53:36Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jeff.li](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jeff.li/32/68813_2.png) [@jeff.li](https://forum.inductiveautomation.com/u/jeff.li)\
**Post date:** [May 29, 2019, 1:53am UTC](https://forum.inductiveautomation.com/t/is-it-possible-to-call-a-script-when-tag-value-changed-in-8-0-1/25381/1 "2019-05-29T01:53:36Z")

</div>

I have one script named ‘Test’ in my project under project Library, when I have one tag value has been changed, I want to call this script, but got error message from logger to say: File “tagevent:valueChanged”, line 11, in valueChanged NameError: global name Test’ is not defined

and if I changed call from Test.method() to project.Test.method(), I will get same error just changed globale name ‘Test’ is not defined to global name ‘project’ not possible

so I want to know for 8.0.1 is it possible to call a script from tag event or only can call the script from gateway event?

thanks a lot!

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [May 29, 2019, 2:29am UTC](https://forum.inductiveautomation.com/t/is-it-possible-to-call-a-script-when-tag-value-changed-in-8-0-1/25381/2 "2019-05-29T02:29:26Z")

</div>

There’s a [gateway setting](https://docs.inductiveautomation.com/display/DOC80/Gateway+Settings) called “Gateway Scripting Project” in 8.0 that dictates which project things like tag event scripts will be able to call libraries from.

On upgrade this gets set to “global”, preserving the behavior from 7.9 where you could called “shared” scripts. On new installs it needs to be set by you.

---

<div class="post-metadata">

**Author:** ![jeff.li](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jeff.li/32/68813_2.png) [@jeff.li](https://forum.inductiveautomation.com/u/jeff.li)\
**Post date:** [May 29, 2019, 3:03am UTC](https://forum.inductiveautomation.com/t/is-it-possible-to-call-a-script-when-tag-value-changed-in-8-0-1/25381/3 "2019-05-29T03:03:37Z")

</div>

Great, it works fine now, thanks again

---

<div class="post-metadata">

**Author:** ![mori.luca](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mori.luca/32/13424_2.png) [@mori.luca](https://forum.inductiveautomation.com/u/mori.luca)\
**Post date:** [June 17, 2020, 6:28pm UTC](https://forum.inductiveautomation.com/t/is-it-possible-to-call-a-script-when-tag-value-changed-in-8-0-1/25381/4 "2020-06-17T18:28:44Z")

</div>

In order to see errors eventually encountered by running scripts in this way are logged in the Log section?
