# Client Tag change script error

**URL:** <https://forum.inductiveautomation.com/t/client-tag-change-script-error/7038>\
**Category:** Ignition\
**Created:** [August 14, 2013, 3:29pm UTC](https://forum.inductiveautomation.com/t/client-tag-change-script-error/7038 "2013-08-14T15:29:02Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![HALW80](https://avatars.discourse-cdn.com/v4/letter/h/47e85d/32.png) [@HALW80](https://forum.inductiveautomation.com/u/HALW80)\
**Post date:** [August 14, 2013, 3:29pm UTC](https://forum.inductiveautomation.com/t/client-tag-change-script-error/7038/1 "2013-08-14T15:29:02Z")

</div>

I am getting the following error:  
NameError: name ‘newValue’ is not defined

while trying to run this script  
value = newValue.value

---

<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:** [August 14, 2013, 3:50pm UTC](https://forum.inductiveautomation.com/t/client-tag-change-script-error/7038/2 "2013-08-14T15:50:25Z")

</div>

Is that really the entirety of your script, or are you trying to simplify for the sake of the forum?

---

<div class="post-metadata">

**Author:** ![adamaustin](https://avatars.discourse-cdn.com/v4/letter/a/5f8ce5/32.png) [@adamaustin](https://forum.inductiveautomation.com/u/adamaustin)\
**Post date:** [August 14, 2013, 4:51pm UTC](https://forum.inductiveautomation.com/t/client-tag-change-script-error/7038/3 "2013-08-14T16:51:54Z")

</div>

Try event.newValue:

```auto
value = event.newValue
```

> [@](#):
>
> Client Tag Change

Err, sorry missed this. Ignore my suggestion.

---

<div class="post-metadata">

**Author:** ![HALW80](https://avatars.discourse-cdn.com/v4/letter/h/47e85d/32.png) [@HALW80](https://forum.inductiveautomation.com/u/HALW80)\
**Post date:** [August 14, 2013, 8:12pm UTC](https://forum.inductiveautomation.com/t/client-tag-change-script-error/7038/4 "2013-08-14T20:12:56Z")

</div>

An if statement follows depending on valve the variable ‘value’ holds  
that part of the script is working ok because if I set value to a constant it operates as expected.  
Its the mapping of the change of number of tag to value that isn’t working

---

<div class="post-metadata">

**Author:** ![HALW80](https://avatars.discourse-cdn.com/v4/letter/h/47e85d/32.png) [@HALW80](https://forum.inductiveautomation.com/u/HALW80)\
**Post date:** [August 15, 2013, 8:10am UTC](https://forum.inductiveautomation.com/t/client-tag-change-script-error/7038/5 "2013-08-15T08:10:35Z")

</div>

its running perfect this morning!!  
not sure what changed!  
thanks for the replies
