Hi Flashdev,
You can call functions inside the child once it's loaded in the parent, using AS3 V2 components, by using the following code:
import flash.display.MovieClip; function registerChild(ev:StudioEvent):void { (mc_loader.getChildAt(0) as MovieClip).myFunction(); //mc_loader is the movieclip which loads the child on the parent file //myFunction() is the function in the child file that you want to call from the parent file
}; // Using ExpandingComponent
Expanding.addEventListener(StudioEvent.LOAD, registerChild); // Using Loader Component
polite.addEventListener(StudioEvent.LOAD, registerChild); |