Duplicate and set _x

Hi guys… :smiley:
i’m trying to duplicate MovieClip in the root to make something like Nav. so i tried and searched a lot of times but i couldn’t find anything helped me…
i want to duplicate and set every new clips his own _x and make it clickable :puzzle: .
here is my code and i think it’s very easy but i can’t figer it :frowning:
[AS]function duplication(trt) {
this.trt = trt;
for (i=0; i<=trt; i++) {
duplicateMovieClip(“test”, “test”+i, i);
_root[“test”+i]._x = _root[“test”+i]._x+60;
}
}
_root.onEnterFrame = function() {
duplication(10);
};[/AS]
thanx

hello,

the previous comments were very helpful to me. I have gotten pretty far with my movie. Basically, my intent is to pull images from a remote folder and create thumbnails which will then be enlarged. I have one issue. I need to be able to claim a maximum number of images rather than claiming a total number of columns and rows. I still need the columns and rows but I want to duplicate the movies within the columns and rows for the total number of images I have.

Here is the code I have currently. It duplicates the outside images based on the column and row total.

[AS]
COLS = 14; // number of columns in grid
ROWS = 2; // number of rows in grid
vSPACING = 40; // spacing between circles in pixels
hSPACING = 23; // spacing between circles in pixels
LEFTMARGIN = 85;
TOPMARGIN = 310;
DEPTH = 0; // starting point for depth
count = 0;
for (i=1; i<=ROWS; i++) {
for (k=1; k<=COLS; k++) {
thumb = this.createEmptyMovieClip(“btn_mc”+i+"_"+k, DEPTH++);
thumb._x = LEFTMARGIN + ((k-1) * (vSPACING + thumb.width));
thumb.y = TOPMARGIN + ((i-1) * (hSPACING + thumb.height));
this[“btn_mc”+i+"
"+k].a = i+"
"+k;
this.a = this_a;
this[“btn_mc”+i+"
"+k].i = DEPTH;
this.thumb.createEmptyMovieClip(“imgHolder_mc”, 1);
this.thumb._xscale = 5;
this.thumb._yscale = 5;
this.thumb.onRelease = function (){
container.loadMovie(“slide/number” + this.i + “.jpg”);
container._x = 100;
container._y = 8;
container._xscale = 70;
container._yscale = 70;
this._alpha = 35;

}
this.thumb.imgHolder_mc.loadMovie(“slide/number” + DEPTH + “.jpg”);
}
}
//create a movie clip to hold the larger images
_root.createEmptyMovieClip(“container”, DEPTH+2);
container.loadMovie(“slide/number1.jpg”);
container._x = 100;
container._y = 8;
container._xscale = 70;
container._yscale = 70;
[/AS]