Hello, I need to load another .swf into an iframe after a .flv fisnishes playing. what is the best way to accomplish this?
Printable View
Hello, I need to load another .swf into an iframe after a .flv fisnishes playing. what is the best way to accomplish this?
The easiest way is to use the FLV Playback component and listen for its "complete" event:
Code:/**
Requires:
- FLVPlayback component on the Stage with an instance name of my_FLVPlybk
*/
import mx.video.*;
var listenerObject:Object = new Object();
listenerObject.complete = function(eventObject:Object):Void {
trace("Elapsed play time at completion is: " + my_FLVPlybk.playheadTime);
};
my_FLVPlybk.addEventListener("complete", listenerObject);
my_FLVPlybk.contentPath = "http://www.helpexamples.com/flash/video/water.flv";