views:

62

answers:

1

I have got an xml file that brings text into a flash movie in the form of an array, I need to population some textboxes and want to do this using a for loop. My loop look like this:

  for(var i=0; i<first_array.length; i++){


   this.animation1.text_mc[i].txt[i].htmlText = first_array[i];


  }

if i hardcode the path, without [i], it works, am i missing something really obvious?

A: 

Hi,

sorted it, so i'll answer my own question:

this.animation1["text_mc" + i]["txt" + i].htmlText = first_array[i];

hopefully this will help someone else.

Marvin

Marvin Speakman