Loading External SWF into Movieclip on stage but enable to trace currentFrame
I have total 4 exter swf naming 1.swf, 2.swf. 3.swf, 4..swf
able to load 1st swf, want to load all the swf in sequance.
var swfNumber:int=1;
var totalSwf:int=4;
var myLoader:Loader = new Loader();
var myRequest:URLRequest = new URLRequest("swf/"+swfNumber+".swf");
myLoader.load(myRequest);
addChild(myLoader);
myLoader.contentLoaderInfo.addEventListener(Event.COMPLETE,loaded);
function loaded(event:Event){
trace("Loaded");
var extSwf = myLoader.content as MovieClip;
trace (extSwf.totalFrames)
trace (extSwf.currentFrame)
if (extSwf.currentFrame==2) {
trace("a")
}
}
Here I am not able to trace a on where I am checking 2nd frame however able to trace a when I checking on 1st frame using below mentioned code
if (extSwf.currentFrame==2) {
trace("a")
}
Any Idea.