Hi 

How do I control the timeline of a loaded swf file (created with the
Flash 8 IDE) with AS 3? My problem is that the "content" property of a
Loader object returns me a display object but not a movieclip. 

I tried casting but my application crashes when I try to run it.

Any ideas?

Robin



// here's my callback function, which is executed once the external swf
is // loaded
private function onLoadComplete(event:Event):void
                {
                        
                         
                        var myDisplayObject:DisplayObject =
myLoader.content;

                        
                        // this creates an run time error
                        loadedSWF = myDisplayObject as MovieClip;
                        loadedSWF.play();
                        
                }

_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to