Hi,
Not sure if this is what is causing my problem.
I have an array called "__viewsArray"
Then I created 3 new movieclips which I added to the Array.
Like this:
__viewsArray = new Array();
__view1MC = new MovieClip();
__view2MC = new MovieClip();
__view3MC = new MovieClip();
addChild(__view1MC);
addChild(__view2MC);
addChild(__view3MC);
__viewsArray.push(__view1MC);
__viewsArray.push(__view2MC);
__viewsArray.push(__view3MC);
Now, I create new instances of Loader and add them to the three viewMC's.
.....
myLoader = new Loader();
myLoader.name = "MC";
myLoader.load(fileRequest);
...
////// I am removing the code of the loader listener, but u can be
sure that I am checking for the load event to complete here...
...
__viewsArray[i].addChild(myLoader);
.....
So far so good.
When I loop through the "__viewsArray", I can do the :
__viewsArray[j].getChildByName("MC");
no errors.
Now, I decide to shuffle the array.
So I did:
var tempArray = __viewsArray.pop();
__viewsArray.unshift(tempArray);
Now when I loop through the array, I get a null object reference.
Is it because I am shuffling the array or is it due to something else?
Cant figure this one out :(
Thanks for any help.
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders