# Adding Movieclips with addchild and a loop...how to target a specific one?

**URL:** <https://forum.kirupa.com/t/adding-movieclips-with-addchild-and-a-loop-how-to-target-a-specific-one/229639>\
**Category:** Uncategorized\
**Created:** [June 19, 2007, 5:19am UTC](https://forum.kirupa.com/t/adding-movieclips-with-addchild-and-a-loop-how-to-target-a-specific-one/229639 "2007-06-19T05:19:23Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![danielKirupin](https://avatars.discourse-cdn.com/v4/letter/d/9de053/32.png) [@danielKirupin](https://forum.kirupa.com/u/danielKirupin)\
**Post date:** [June 19, 2007, 5:19am UTC](https://forum.kirupa.com/t/adding-movieclips-with-addchild-and-a-loop-how-to-target-a-specific-one/229639/1 "2007-06-19T05:19:23Z")

</div>

I have this code:

* * *

for(var i:Number = 0; i \< 10; i++) {

```
    buttonVar = new button();
    addChild(buttonVar);  
    buttonVar.x = i*120;

```

## }

It creates a 10 movieclips and moves them apart 120 units, what I want is to target a specific created movie clip. Say for example the number 4 in the loop, how can I asign a specific instance to that movieclip? to differentiatte it from the other ones ? any idea ?
