# A question about enterFrame and multiple instances

**URL:** <https://forum.kirupa.com/t/a-question-about-enterframe-and-multiple-instances/312415>\
**Category:** flash\
**Created:** [August 2, 2010, 11:29pm UTC](https://forum.kirupa.com/t/a-question-about-enterframe-and-multiple-instances/312415 "2010-08-02T23:29:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rrobnett](https://avatars.discourse-cdn.com/v4/letter/r/73ab20/32.png) [@rrobnett](https://forum.kirupa.com/u/rrobnett)\
**Post date:** [August 2, 2010, 11:29pm UTC](https://forum.kirupa.com/t/a-question-about-enterframe-and-multiple-instances/312415/1 "2010-08-02T23:29:31Z")

</div>

Hi,  
Here is what I’m doing.  
In the library of the FLa I have a symbol that is exported for actionscript with a class name of ‘aClip’.  
I am placing multiple instances of it on stage as follows:

```auto
 
for (var i:int = 0; i < 10; i++) {
 var myClip:aClip = new aClip();
 myClip.x = 0;
 myClip.y = 50 + (50 * i);
}

```

Each myClip will move across the stage at 1 unit per frame. If I only had 1 instance on the stage I would implement as follows:

```auto
 
//make an enterFrame listener for the stage
this.addEventListener(Event.ENTER_FRAME, moveClip);
//make a function for the listener
function moveClip(e:Event):void {
 myClip.x += 1;
}

```

The problem I am having, is getting this to work for the multiple instances generated in the for loop.

I know this has been discussed before, but doing a search has been no help.

I would appreciate any help.  
rrobnett
