# as3 Watcher

**URL:** <https://forum.kirupa.com/t/as3-watcher/247348>\
**Category:** flash\
**Created:** [December 21, 2007, 3:31pm UTC](https://forum.kirupa.com/t/as3-watcher/247348 "2007-12-21T15:31:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mygrafik](https://avatars.discourse-cdn.com/v4/letter/m/4da419/32.png) [@mygrafik](https://forum.kirupa.com/u/mygrafik)\
**Post date:** [December 21, 2007, 3:31pm UTC](https://forum.kirupa.com/t/as3-watcher/247348/1 "2007-12-21T15:31:00Z")

</div>

hi

as2 code

```auto

var Watcher:Function = function(prop, oldVal, newVal ):Number {
 trace( newVal )
    return newVal;
}
_root.watch("x_var", Watcher, 55);
x_var = 10

```

as3 code

```auto
  ?...  

```

---

<div class="post-metadata">

**Author:** ![mcarey](https://avatars.discourse-cdn.com/v4/letter/m/6de8d8/32.png) [@mcarey](https://forum.kirupa.com/u/mcarey)\
**Post date:** [July 14, 2008, 7:25pm UTC](https://forum.kirupa.com/t/as3-watcher/247348/2 "2008-07-14T19:25:15Z")

</div>

(maybe much too late to pic up this thread, but I’ll try…)

what if you’re trying to ‘watch()’ a system level var/prop, such as loaderInfo.parameters for update ( see [http://www.kirupa.com/forum/showthread.php?t=289313](http://www.kirupa.com/forum/showthread.php?t=289313) , for context - communication with a c++ or vb wrapper )… in that case a custom ‘set’ accessor method won’t work ( ie, set loaderInfo.parameters.myParam(val:\*)… )

thoughts?

---

<div class="post-metadata">

**Author:** ![senocular](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/senocular/32/7217_2.png) [@senocular](https://forum.kirupa.com/u/senocular)\
**Post date:** [July 14, 2008, 7:26pm UTC](https://forum.kirupa.com/t/as3-watcher/247348/3 "2008-07-14T19:26:59Z")

</div>

SOL. You’ll have to set up a poller or create your own get/set API if possible
