var elt = elts[x];
fl.trace("Element "+ x +" Name = " + elt.name + " Type = " + elt.elementType
+ " location = " + elt.left + "," + elt.top + " Depth = " + elt.depth);
}
element.getPersistentData()
Availability
Flash MX 2004.
Usage
element.getPersistentData( name )
Parameters
A string that identifies the data to be returned.
name
Returns
The data specified by the
Description
Method; retrieves the value of the data specified by the
on the type of the data that was stored (see
bitmaps support persistent data.
Example
The following example sets and gets data for the specified element, shows its value in the Output
panel, and then removes the data:
// at least one symbol or bitmap is selected in the first layer, first frame
var elt = fl.getDocumentDOM().getTimeline().layers[0].frames[0].elements[0];
elt.setPersistentData("myData","integer", 12);
if (elt.hasPersistentData("myData")){
fl.trace("myData = "+ elt.getPersistentData("myData"));
elt.removePersistentData( "myData" );
fl.trace("myData = "+ elt.getPersistentData("myData"));
}
element.hasPersistentData()
Availability
Flash MX 2004.
Usage
element.hasPersistentData( name )
Parameters
A string that specifies the name of the data item to test.
name
parameter, or 0 if the data doesn't exist.
name
element.setPersistentData()
parameter. The type of data depends
name
). Only symbols and
Element object
151
Need help?
Do you have a question about the FLASH MX 2004-FLASH JAVASCRIPT DICTIONARY and is the answer not in the manual?