I have a for loop that creates a set of movieclips(that have other movieclips, textfields etc in them) that are kept in an array. How do I reference the moviclips and textfields that are within the array’s movieclips?
I have no problem referencing the movieclips in the array, by using infoArray*, it is the other dynamically added content that is embedded within the original movieclip.
Any help would be most welcome
Thanks
here is what I have
var infoArray:Array = new Array;
var infoNum:Number = 10;
function addContent(){
var textHolder:MovieClip = new MovieClip;
container.addChild(textHolder);
var heading1:TextField = new TextField();
heading1.text = “HEADING”;
textHolder.addChild(heading1);
var heading2:TextFiled = new TextField();
heading2.text = i;
heading1.embedFonts = true;
heading2.embedFonts = true;
var info:MovieClip = new mc_infoPanel;
container.addChild(info);
}
for (var i=1; i<infoNum; i++){
var space:Number = 2;
var container:MovieClip = new mc_container;
container.x = ((space + container.width) * i) - (space + container.width);
addContent();
infoArray* = container;
}