User Guide
112 Chapter 6: Components Dictionary
Returns
Nothing.
Description
Method (inherited from View); destroys one of the accordion’s children. The child to be
destroyed is specified by its index, which is passed to the method in the
index parameter. Calling
this method destroys the corresponding header as well.
If the destroyed child is selected, a new selected child is chosen. If there is a next child, it is
selected. If there is no next child, the previous child is selected. If there is no previous child, the
selection is undefined.
Note: Calling destroyChildAt() decreases the numChildren property by 1.
Example
The following code destroys the last child of myAccordion:
myAccordion.destroyChildAt(myAccordion.numChildren - 1);
See also
Accordion.createChild()
Accordion.getChildAt()
Availability
Flash Player 6 (6.0 79.0).
Edition
Flash MX Professional 2004.
Usage
myAccordion.getChildAt(index)
Parameters
index
The index number of an accordion child. Each child of an accordion is assigned a
zero-based index in the order in which it was created.
Returns
A reference to the instance of the UIObject at the specified index.
Description
Method; returns a reference to the child at the specified index. Each accordion child is given an
index number for its position. This index number is zero-based, so the first child is 0, the second
child is 1, and so on.
Example
The following code gets a reference to the last child of myAccordion:
var lastChild:UIObject = myAccordion.getChildAt(myAccordion.numChildren - 1);