Waiting for a movieClip to finish

Posted on 2005-04-22
Medium Priority
Last Modified: 2008-02-01
Hi there.

--- THE STATUS ---
I've build a flash app with two main modules:
- First is the front-end. It just includes backgrounds, buttons and an empty movieClip to load whatever to be displayed.
- Then there are n tiny SWFs that will be loaded dinamically when the user clicks on the front-end buttons.

Each one of these tiny SWF includes a transition effect before displayed (unrolling), then show the contents (and stop), and a rolling effect to do before unloading.

--- THE CODE ---
this["button" + i].onRelease = function () {
  content.gotoAndPlay(3);  // starts the ending animation
  loadMovie("new-movie-to-load.swf", content);
// Tip: content is just an empty mc used to load all the SWFs to be shown.

The rolling effect is never show, because of (i guess) it's unloaded before ending the execution. How can i wait for the SWF movie to finish before unloading it?
Question by:Kkto
1 Comment
LVL 18

Accepted Solution

Billystyx earned 750 total points
ID: 13842018
check for the last frame of that mc, or put the call to unload the next mc in the loaded swf.

With the second option - not sure how unloading works from a loaded swf, so you can do this - on last frame of the loaded swf, put this:


then check for that in your code:


with first option,  put this in your code


Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are times in your Flash CS4 application when you want more than a simple pointer or a hand, and it's hard to find an ideal walk-through to tell you what to do.  I spent a few days recently learning my way around making custom cursors in Flash,…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
The goal of the tutorial is to teach the user how to select the video input device. Make sure you have an input device that in connected and work and recognized by Adobe Flash Media Live Encoder and select it in the “video input” menu.
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.
Suggested Courses
Course of the Month16 days, 20 hours left to enroll

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question