Jump to content
Search Community

SWFLoader Stop()

jhakooz test
Moderator Tag

Recommended Posts

Hi,

Honestly, I tried to figure out this seemingly easy question before posting!

 

I would like my loaded SWF to stop once it's loaded. Basically, I need to call stop() on the SWFLoader as soon as possible.

 

I think what I need to do is set autoPlay:false (which it is) and somehow convert SWFLoader content to a movieclip in my onComplete handler... then call stop(). From what I can tell I would need to use rawContent, but for the life of me I cannot convert SWFLoader to a MovieClip.

 

So.... How can I reference my SWFLoader as a movieclip in onComplete, so that I can call stop()?

Something like autoStop:true would kick butt, but a little too late for that suggestions, huh?

 

Thanks!

Joe

Link to comment
Share on other sites

Yeah, Flash denies script access to AVM1Movies (AS2 swfs loaded into an AS3 app). So in that case, SWFLoader cannot reference the MovieClip directly without throwing an error, so in that particular case, its rawContent is the Loader instance instead of the AS2 swf's root.

 

So are you all set now? Sounds like you figured it out.

Link to comment
Share on other sites

Yeah, I'm all set now. Thanks Jack...

 

Unless you have a class that can convert AS2 programmers to AS3?

Something like...

var dude:AS3Dude = new AS3Dude("http://www.aol.com/couch/lazy.mofo", {timeScale:3} );

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...