Unloadmovie Function; Unloadmovienum Function - MACROMEDIA FLASH 8-FLASH LITE 2.X ACTIONSCRIPT LANGUAGE Reference

Flash lite 2.x actionscript language reference
Hide thumbs Also See for FLASH 8-FLASH LITE 2.X ACTIONSCRIPT LANGUAGE:
Table of Contents

Advertisement

unloadMovie function

unloadMovie(target:MovieClip) : Void unloadMovie(target:String) : Void
Removes a movie clip that was loaded by means of
a movie clip that was loaded by means of
of
.
unloadMovie()
Availability: ActionScript 1.0; Flash Lite 1.1
Parameters
- The target path of a movie clip. This parameter can be either a String (e.g.
target
"my_mc") or a direct reference to the movie clip instance (e.g. my_mc). Parameters that can
accept more than one data type are listed as type
Example
The following example creates a new movie clip called
clip. It is loaded using the MovieClipLoader class. When you click the image, the movie clip
unloads from the SWF file:
var pic_mcl:MovieClipLoader = new MovieClipLoader();
pic_mcl.loadClip("http://www.helpexamples.com/flash/images/image1.jpg",
this.createEmptyMovieClip("pic_mc", this.getNextHighestDepth()));
var listenerObject:Object = new Object();
listenerObject.onLoadInit = function(target_mc) {
target_mc.onRelease = function() {
unloadMovie(pic_mc);
/* or you could use the following, which refers to the movie clip
referenced by 'target_mc'. */
//unloadMovie(this);
};
};
pic_mcl.addListener(listenerObject);
See also
loadMovie (MovieClip.loadMovie method)
(MovieClipLoader.unloadClip method)

unloadMovieNum function

unloadMovieNum(level:Number) : Void
Removes a SWF or image that was loaded by means of loadMovieNum() from Flash Player.
To unload a SWF or image that was loaded with
instead of
unloadMovie()
loadMovieNum()
,
.
unloadMovieNum()
from Flash Player. To unload
loadMovie()
, use
unloadMovieNum()
.
Object
and loads an image into that
pic_mc
unloadClip
MovieClip.loadMovie()
instead
, use
Global Functions
91

Advertisement

Table of Contents
loading

Table of Contents