Referencing/loading a dynamically created movieclip variable

Hi there,

Its my first post, but I’m hoping someone out there can help me!

I am trying to load an image in to a dynamically created movieclip, which is:

_root.mySlider."+stripX2(band*[0])+i

but I can’t seem to reference it. I can load the movie into _root.mySlider, but if I add the dynamic element (stripX2(band*[0])+i) without quotes it it doesn’t load. If I load with quotes

i.e.

“_root.mySlider.”+stripX2(band*[0])+i

flash doesn’t allow strings in movieClip variables

The code I’m using is belowm, it’s the second to last line thats causing the problem:

var loadListener:Object = new Object();
loadListener.onLoadComplete = function(target_mc:MovieClip):Void {
trace(">> target_mc._width: “+target_mc._width);
};
loadListener.onLoadInit = function(target_mc:MovieClip):Void {
trace(”>> target_mc._width: "+target_mc._width);
};
var mcLoader:MovieClipLoader = new MovieClipLoader();
mcLoader.addListener(loadListener);
var mc:MovieClip = _root.mySlider.createEmptyMovieClip(“mc”, this.getNextHighestDepth());

mcLoader.loadClip(inBead.bead_loc, mc);

Many Thanks!

_root.mySlider[stripX2(band*[0])+i]

That’s perfect, many thanks!