# Property Change script on Root Container Not Executing

**URL:** <https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [December 15, 2020, 4:01pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531 "2020-12-15T16:01:18Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![dandersen](https://avatars.discourse-cdn.com/v4/letter/d/ecb155/32.png) [@dandersen](https://forum.inductiveautomation.com/u/dandersen)\
**Post date:** [December 15, 2020, 4:01pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/1 "2020-12-15T16:01:18Z")

</div>

I have a custom property on a Root Container and I’m trying to get the property change script to fire if I change the customer property. It doesn’t seem to do that. I’m trying to change `partNum1` for example and I don’t get the print statement in the Console. Am I missing something?

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/0/308f53347ca71385a01729e36b5368350d156852.png)  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/8/8/882035312c5a3b89c139ae7d217ed0a9509f438c.png)

---

<div class="post-metadata">

**Author:** ![bpreston](https://avatars.discourse-cdn.com/v4/letter/b/4af34b/32.png) [@bpreston](https://forum.inductiveautomation.com/u/bpreston)\
**Post date:** [December 15, 2020, 4:02pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/2 "2020-12-15T16:02:47Z")

</div>

Are you doing this in designer or a client?

If your in designer, do you have your designer set to run?

---

<div class="post-metadata">

**Author:** ![dandersen](https://avatars.discourse-cdn.com/v4/letter/d/ecb155/32.png) [@dandersen](https://forum.inductiveautomation.com/u/dandersen)\
**Post date:** [December 15, 2020, 4:03pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/3 "2020-12-15T16:03:02Z")

</div>

Designer

---

<div class="post-metadata">

**Author:** ![bpreston](https://avatars.discourse-cdn.com/v4/letter/b/4af34b/32.png) [@bpreston](https://forum.inductiveautomation.com/u/bpreston)\
**Post date:** [December 15, 2020, 4:04pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/4 "2020-12-15T16:04:53Z")

</div>

You replied while I was writing back to see if you have designer set to run.

Also your print statement should just be:

```auto
print "test"

```

But for testing this and with where you have it located, I would try:

```auto
print event.propertyName

```

---

<div class="post-metadata">

**Author:** ![dandersen](https://avatars.discourse-cdn.com/v4/letter/d/ecb155/32.png) [@dandersen](https://forum.inductiveautomation.com/u/dandersen)\
**Post date:** [December 15, 2020, 4:06pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/5 "2020-12-15T16:06:03Z")

</div>

I have tried all of those and it doesn’t make a difference. I normally use print"" but I had swapped back for a test to make sure it wasn’t having and issue. What I’m trying to say is the propertyChange script never executes as I get no print statement.

---

<div class="post-metadata">

**Author:** ![dandersen](https://avatars.discourse-cdn.com/v4/letter/d/ecb155/32.png) [@dandersen](https://forum.inductiveautomation.com/u/dandersen)\
**Post date:** [December 15, 2020, 4:08pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/6 "2020-12-15T16:08:46Z")

</div>

Here is the script now. I get no output in the console when I change those specific properties.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/6/d/6dd4f5084e76586cb4116ba222824b810d73d06b.png)

---

<div class="post-metadata">

**Author:** ![bpreston](https://avatars.discourse-cdn.com/v4/letter/b/4af34b/32.png) [@bpreston](https://forum.inductiveautomation.com/u/bpreston)\
**Post date:** [December 15, 2020, 4:10pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/7 "2020-12-15T16:10:17Z")

</div>

As long as the designer is set to run, you should at least be getting the print. I can’t think of any reason it wouldn’t fire with it being the first thing in line. Even if the script fails, it would fail after so I’m not sure. I do know if the designer isn’t in preview mode(or what I keep calling run) then property changes don’t happen so it wouldn’t print anything.

---

<div class="post-metadata">

**Author:** ![dandersen](https://avatars.discourse-cdn.com/v4/letter/d/ecb155/32.png) [@dandersen](https://forum.inductiveautomation.com/u/dandersen)\
**Post date:** [December 15, 2020, 4:11pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/8 "2020-12-15T16:11:35Z")

</div>

Ah there you go. I didn’t have it in run mode. Figured it would be something simple like that.

---

<div class="post-metadata">

**Author:** ![bpreston](https://avatars.discourse-cdn.com/v4/letter/b/4af34b/32.png) [@bpreston](https://forum.inductiveautomation.com/u/bpreston)\
**Post date:** [December 15, 2020, 4:12pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/9 "2020-12-15T16:12:31Z")

</div>

It normally is but those little things get us all at different times.

---

<div class="post-metadata">

**Author:** ![dandersen](https://avatars.discourse-cdn.com/v4/letter/d/ecb155/32.png) [@dandersen](https://forum.inductiveautomation.com/u/dandersen)\
**Post date:** [December 15, 2020, 4:13pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/10 "2020-12-15T16:13:24Z")

</div>

It’s weird because I do get other property Change events to print without being in run mode. Maybe different components act differently on it.

---

<div class="post-metadata">

**Author:** ![bpreston](https://avatars.discourse-cdn.com/v4/letter/b/4af34b/32.png) [@bpreston](https://forum.inductiveautomation.com/u/bpreston)\
**Post date:** [December 15, 2020, 4:15pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/11 "2020-12-15T16:15:50Z")

</div>

I’m not sure, I don’t remember ever seeing any running without being in run/preview mode.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [December 15, 2020, 5:10pm UTC](https://forum.inductiveautomation.com/t/property-change-script-on-root-container-not-executing/41531/12 "2020-12-15T17:10:27Z")

</div>

You might be confusing runScript() with propertyChange events. runScript() operates even without preview mode.
