MovieClipLoader.loadClip() 547
Example
See MovieClipLoader.loadClip().
See also
MovieClipLoader.onLoadProgress()
MovieClipLoader.loadClip()
Availability
Flash Player 7.
Usage
my_mcl.loadMovie("url", target )
Parameters
url
The absolute or relative URL of the SWF file or JPEG file to be loaded. A relative path
must be relative to the SWF file at level 0. Absolute URLs must include the protocol reference,
such as http:// or file:///. Filenames cannot include disk drive specifications.
target The target path of a movie clip, or an integer specifying the level in Flash Player into
which the movie will be loaded. The target movie clip will be replaced by the loaded movie
or image.
Returns
Nothing.
Description
Method; loads a SWF or JPEG file into a movie clip in Flash Player while the original movie is
playing. Using this method lets you display several movies at once and switch between movies
without loading another HTML document.
Using this method instead of
loadMovie() or MovieClip.loadMovie() has a number of
advantages:
• The MovieClipLoader.onLoadStart() handler is invoked when loading begins.
• The MovieClipLoader.onLoadError() handler is invoked if the clip cannot be loaded.
• The MovieClipLoader.onLoadProgress() handler is invoked as the loading process progresses.
• The MovieClipLoader.onLoadInit() handler is invoked after the actions in the first frame of
the clip have executed, so you can being manipulating the loaded clip.
A movie or image loaded into a movie clip inherits the position, rotation, and scale properties of
the movie clip. You can use the target path of the movie clip to target the loaded movie.
You can use this method to load one or more files into a single movie clip or level;
MovieClipLoader listener objects are passed the loading target movie clip instance as a parameter.
Alternately, you can create a different MovieClipLoader object for each file you load.
Use
MovieClipLoader.unloadClip() to remove movies or images loaded with this method or
to cancel a load operation that is in progress.