Example
The following example displays
or
in the Output panel for each specified file,
true
false
depending on whether the file exists.
alert(fl.fileExists("file:///C|/example.fla"));
alert(fl.fileExists("file:///C|/example.jsfl"));
alert(fl.fileExists(""));
fl.findDocumentIndex()
Availability
Flash MX 2004.
Usage
fl.findDocumentIndex( name )
Parameters
The document name for which you want to find the index. The document must be
name
open.
Returns
An array of integers that represent the position of the document
in the
name
fl.documents
array.
Description
Method; returns an array of integers that represent the position of the document
in the
name
array. More than one document with the same name can be open (if the
fl.documents
documents are located in different folders).
Example
The following example displays information about the index position of any open files named
test.fla in the Output panel:
var filename = "test.fla"
var docIndex = fl.findDocumentIndex(filename);
for (var index in docIndex)
fl.trace(filename + " is open at index " + docIndex[index]);
See also
fl.documents
flash object (fl)
237
Need help?
Do you have a question about the FLASH 8-EXTENDING FLASH and is the answer not in the manual?