# Looping CreateEmptyMovieClip not working

**URL:** <https://forum.kirupa.com/t/looping-createemptymovieclip-not-working/216913>\
**Category:** flash\
**Created:** [February 21, 2007, 4:30pm UTC](https://forum.kirupa.com/t/looping-createemptymovieclip-not-working/216913 "2007-02-21T16:30:00Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![imvain2](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/imvain2/32/620_2.png) [@imvain2](https://forum.kirupa.com/u/imvain2)\
**Post date:** [February 21, 2007, 4:30pm UTC](https://forum.kirupa.com/t/looping-createemptymovieclip-not-working/216913/1 "2007-02-21T16:30:00Z")

</div>

I have the code below which should loop and createemptymovieclips, however it does loop with no errors but the movieclips don’t get created. I know they don’t get created because I can’t do a loadmovie, however if I try to manually create these (ie, a new line for each createempty, it does work).

```auto
for(X=0;X<=39;X++){
idepth = X + 130;
eval("z_Brickmc_"+X+" = this.createEmptyMovieClip(\"zBrick"+X+"_mc\","+idepth+");");
}

```
