# An .onEnterFrame Question (AS MX)

**URL:** <https://forum.kirupa.com/t/an-onenterframe-question-as-mx/121060>\
**Category:** Uncategorized\
**Created:** [August 30, 2004, 4:44pm UTC](https://forum.kirupa.com/t/an-onenterframe-question-as-mx/121060 "2004-08-30T16:44:27Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![grappaFruit](https://avatars.discourse-cdn.com/v4/letter/g/43a26b/32.png) [@grappaFruit](https://forum.kirupa.com/u/grappaFruit)\
**Post date:** [August 30, 2004, 4:44pm UTC](https://forum.kirupa.com/t/an-onenterframe-question-as-mx/121060/1 "2004-08-30T16:44:27Z")

</div>

A simple topic i’m breaking my head about…

I’m creating a complex site, with lots of calculations, while I have to keep it as light as possible. I don’t want to have 50 [color=slategray].onEnterFrame[/color][color=black]'s[/color] running simultaniously, so, how do I stop them? See example:

Let’s say I want a simple movement, invoked by some reason:

```auto
 
 
mcChild.onEnterFrame = function(){
if(mcChild._x < mcParent._width){
mcChild._x += 5;
}
}

```

Now I want to stop the [color=slategray].onEnterFrame[/color] check, because it reached the [color=slategray]if = false[/color][color=black] - How??[/color]

Cheers
