Parent - MACROMEDIA FLASH MX 2004-ACTIONSCRIPT LANGUAGE Reference

Actionscript language reference
Table of Contents

Advertisement

_parent

Availability
Flash Player 5.
Usage
_parent.property
_parent._parent.property
Description
Identifier; specifies or returns a reference to the movie clip or object that contains the current
movie clip or object. The current object is the object containing the ActionScript code that
references
_parent
the current movie clip or object.
Example
In the following example, there is a movie clip on the Stage with the instance name
Within that movie clip is another movie clip with an instance name
ActionScript lets you modify the
circle is clicked. When you are working with relative addressing (using
), it might be easier to use the Insert Target Path button in the Actions panel at first.
_root
this.square_mc.circle_mc.onRelease = function() {
this._parent._alpha -= 5;
};
See also
_root,
targetPath()
684
Chapter 2: ActionScript Language Reference
ActionScript Language Reference
. Use
to specify a relative path to movie clips or objects that are above
_parent
circle_mc
parent instance (which is
CHAPTER 2
square_mc
The following
circle_mc.
) when the
square_mc
instead of
_parent
.

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH MX 2004-ACTIONSCRIPT LANGUAGE and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Flash mx

Table of Contents