Hi all,
More AS woes,
I have a script attachs btns with a loop and places names in them from an array, this all works fine but I need to space them with the loop as well so
[AS]
clip._x = 20
clip._y = 20*i
[/AS]
this will always start the _y at 0 cos i in the loop will always start at 0
Is there a way to start the y at any number and then still place the other btns under it, without putting the btn in a holder movieclip that I then place.
[AS]
btn_arr = [" Button one", " Button two", " Button three", " Button four"];
for (x=0; x<btn_arr.length; x++) {
var clip = this.attachMovie(“btn_mc”, “btn_mc”+x, x);
clip._x = 5;
clip._y = 27*x;
clip.btn_txt.text = btn_arr[x];
clip.link = link_arr[x];
clip.useHandCursor = false;
clip.onRollOver = function() {
this.nextFrame();
};
clip.onRollOut = function() {
this.prevFrame();
};
}
[/AS]