# For Loop and onRelease

**URL:** https://forum.kirupa.com/t/for-loop-and-onrelease/222441
**Category:** flash
**Created:** [April 13, 2007, 2:45pm UTC](https://forum.kirupa.com/t/for-loop-and-onrelease/222441 "2007-04-13T14:45:07Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![saveth](https://avatars.discourse-cdn.com/v4/letter/s/7c8e57/32.png) [@saveth](https://forum.kirupa.com/u/saveth)
#### Post date: [April 13, 2007, 2:45pm UTC](https://forum.kirupa.com/t/for-loop-and-onrelease/222441/1 "2007-04-13T14:45:07Z")

</div>

I’ve tried a couple things so far to figure this out without any success. Please let me know if you see any quick fixes for this.

Thanks,  
Saveth

```auto

var booths:Array = new Array();

for(var i=1; i<15; i++){
    booths* = "booth_" + i + "_mc";
}

for(var i=1; i<15; i++){
    container_mc.booths*.id = i;
    container_mc.booths*.onRelease = function () {
        trace(booths[this.id]);
    }
}

```
