Flash Player 6.
my_mc.createEmptyMovieClip(instanceName:String, depth:Number) : MovieClip
instanceName A string that identifies the instance name of the new movie clip.
depth An integer that specifies the depth of the new movie clip.
A reference to the newly created movie clip.
Method; creates an empty movie clip as a child of an existing movie clip. This method behaves similarly to the attachMovie() method, but you don't need to provide an external linkage identifier for the new movie clip. The registration point for a newly created empty movie clip is the upper left corner. This method fails if any of the parameters are missing.
You can extend the methods and event handlers of the MovieClip class by creating a subclass. For more information, see "Assigning a class to a movie clip symbol" in Using ActionScript in Flash.
The following ActionScript creates a new movie clip at runtime and loads a JPEG image into the movie clip.
this.createEmptyMovieClip("logo_mc", this.getNextHighestDepth());
logo_mc.loadMovie("http://www.macromedia.com/images/shared/product_boxes/80x92/studio_flashpro.jpg");
MovieClip.attachMovie()
RSS feed | Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/flash/mx2004/main_7_2/00001491.html
Comments
recoveredfromflashMX2004 said on Aug 4, 2004 at 3:18 PM : recoveredfromflashMX2004 said on Aug 4, 2004 at 3:20 PM : Graham Butcher said on Nov 12, 2004 at 9:02 AM : Fumio Nonaka said on Dec 5, 2004 at 2:04 AM :