How to find totalFrames of Captivate 4 .swf in Flash CS4
I have a series of Captivate4 AS3 .swf files that I am loading into an interface created in Flash CS4. The files are loading and playing correctly, but I need to find a way to detect when an imported .swf gets to the end of it's timeline so that I can load the next one.
Here's my code:
var myLoader:Loader = new Loader();
var movieURL:String = "resources/testTestTest.swf";
var req:URLRequest = new URLRequest(movieURL);
var currentMovie;
var endShow:Boolean = false;
myLoader.addEventListener(Event.COMPLETE, loadComplete);
function loadComplete(evt:Event)
{
currentMovie = myLoader.content;
currentMovie.rdcmndPause = 0; //fails to pause imported .swf
trace(currentMovie.cpInfoCurrentDate); //fails to trace out
}
addChild(myLoader);
myLoader.load(req);
Please, help!!
