# Problem!

**URL:** <https://forum.kirupa.com/t/problem/23382>\
**Category:** Uncategorized\
**Created:** [June 17, 2003, 9:49am UTC](https://forum.kirupa.com/t/problem/23382 "2003-06-17T09:49:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![radicaljugnu](https://avatars.discourse-cdn.com/v4/letter/r/df705f/32.png) [@radicaljugnu](https://forum.kirupa.com/u/radicaljugnu)\
**Post date:** [June 17, 2003, 9:49am UTC](https://forum.kirupa.com/t/problem/23382/1 "2003-06-17T09:49:49Z")

</div>

Hello all.

I’ve been trying to get this effect of having one movie clip duplicated several times to get a box like effect like-

o o o o o o o  
o o o o o o o  
o o o o o o o

I tried using -

onClipEvent(load){

for(i=0;i\<100;i++){

this.duplicateMovieClip(“movieclip”+i,i)  
\_root[“movieclip”+i].\_x=movieclip.\_x + (movieclip.\_width+5)\*i

}

but this only duplicates it in a straight line. How do i get the \_y also??

PS. I am using flash 5 so don’t send me mx flas.

Thanx

:goatee:

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [June 17, 2003, 11:07am UTC](https://forum.kirupa.com/t/problem/23382/2 "2003-06-17T11:07:47Z")

</div>

Hi,

use this code of frame  
box is movie clip instance name::

depth = 1;  
xpos =box.\_x;  
ypos =box.\_y;  
while (i\<=5) {  
j = 1;  
while (j\<=5) {  
duplicateMovieClip(“box”, “box” add depth, depth);  
\_root[“box” add depth].\_x=xpos  
\_root[“box” add depth].\_y=ypos  
ypos += box.\_height;  
depth += 1;  
j += 1;  
}  
ypos =box.\_y;  
xpos += box.\_width;  
i += 1;  
}

Rgards,  
Ajo
