MovieClip.attachMovie - Clarification
Can I attachMovie from a loaded SWF into any other timeline?? No, sorry, it's lame, you can't. Just like you can't duplicationMovie to another timeline - again, lame lame lame! But a post on the LiveDocs I posted a while back has some people thinking that I *can* do this or that I found a *way*. I haven't, I've just had to work around it like everyone else. I don't know if this is fixed in 8ball or not, but one can only hope.
The work arounds I've done usually include designing my code to build WITHIN the loaded SWF (that has the library assets I wish to attach).
So, IE:
1. load swf into movie clip _level0.mc_0
2. AFTER the loaded swf is completely loaded, createEmptyMovieClip INSIDE of _level0.mc_0 called "content_mc"
3. AttachMovie (from level0) into _level0.mc_0.content_mc
4. Now, you can attachMovie from _level0.mc_0 into your main content.
So essentially, you're not having your main content out on stage, then loading a SWF to do attachMovie with. You're creating a movieclip that will be attached AFTER you load the swf that has library items you wish to attach to your main content.
Hope that all makes sense! I did this with a jigsaw puzzle app where the image/video had to be dynamic on a day-to-day basis - worked great!
hth, - John
Comments