Need Help controlling external SWFs loaded into MovieClip - AS3

Doing a little hair-pulling today. I have a main timeline with two empty movie clips (originalMC, newMC). I’m loading external SWFs into each. The SWFs are in the same folder as the main file. They load fine and my EventListeners are triggering the trace functions as expected.

I need the ability to stop the playback of the external SWFs when they load but everything I’ve tried creates errors or just plain fails. What do I need to add to the functions (stopNew and stopOriginal) to prevent them from playing? Code below. Thanks.

// Loaders for newMC and originalMC

var loader:Loader=new Loader();
loader.contentLoaderInfo.addEventListener(Event.COMPLETE,stopOriginal);
loader.load(new URLRequest("original.swf"));
originalMC.addChild(loader);

var loader2:Loader=new Loader();
loader2.contentLoaderInfo.addEventListener(Event.COMPLETE,stopNew);
loader2.load(new URLRequest("new.swf"));
newMC.addChild(loader2);

function stopNew(e:Event):void{
trace("new loaded");
// The trace works on export so the function is being called
// I would like this function to stop the timeline of "newMC"
}

function stopOriginal(e:Event):void{
trace("original loaded");
// The trace works on export so the function is being called
// I would like this function to stop the timeline of "originalMC"
}

What have you tried?

The COMPLETE event should technically work, but what you really want is the INIT event.
http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/display/LoaderInfo.html#event:init

This occurs when the movie is initialized and starting to play (though not necessarily complete since SWFs can play as they download). Its always before COMPLETE, though, so your event timing shouldn’t put you anywhere where your child movies are inaccessible as far as I can tell.

Thanks. I got it to work using the code below. Swapping COMPLETE for INIT also works.

var i =new Loader();
i.contentLoaderInfo.addEventListener(Event.COMPLETE,originalloaded);
i.load(new URLRequest(“Optimized_no_device_type.swf”));
originalMC.addChild(i)

function originalloaded(e:Event){
originalMC = e.target.content as MovieClip;
originalMC.stop();
trace(“first movie loaded”);
}