PDA

View Full Version : targetting mc's in a for loop?


zebbah
02-04-2003, 12:07 PM
hello! how can i get several mc's to play with a for loop? for (i = 1; i <= 8; i++) {
"mc" + i;
} how can i get "mc1"-"mc8" to play? i have tried different things but they don't play. anyone know how i can do this?

thnx! :)

avatar
02-04-2003, 01:33 PM
Hi zebbah,

U were nearly there... :)
Try this instead:

for (i = 1; i <= 8; i++) {
_root["mc"+i].gotoAndPlay("start");
}

zebbah
02-05-2003, 07:22 PM
ahh! thnx a lot, avatar! :D