• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Hour 20. Designing a Website to Be Modul... > Determining When a Movie Is Fully Lo...

Determining When a Movie Is Fully Loaded and How to Unload It

Now that you know how to load an image or .swf, it's a good idea to learn how to unload it. But first, you should learn how to determine whether a movie that's loading has completed loading! This will be important if the movie that's loading is large. It's nice to let the user see that a movie is indeed downloading. You might actually want to make the user wait for it to fully load. All these things require you to determine whether a loading movie has downloaded.

The best way to determine whether a movie has loaded is to set up a so-called listener that waits for the onLoadComplete event. But that doesn't happen until the .swf or image is fully loaded. You can use the onLoadProgress event to get up-to-the-minute information about how the downloading is progressing. This way, you can display information to the user (such as a progress bar). That's just what we'll do in the next task.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint