Form.rootForm

Availability

Flash Player 6 (6.0.79.0).

Edition

Flash MX Professional 2004.

Usage

myForm.rootForm

Description

Property (read-only); returns the form at the top of the form hierarchy that contains myForm. If myForm is contained by an object that is not a form (that is, a slide), this property returns myForm.

Example

In the following example, a reference to the root form of myForm is placed in a variable named root. If the value assigned to root refers to myForm, then myForm is at the top of its form tree.

var root:mx.screens.Form = myForm.rootForm;
if(root == myForm) {
    trace("myForm is the top form in its tree");
}