Project object
351
project.addFile()
Availability
Flash 8.
Usage
project.addFile(
fileURI
[ ,
autoCreateFolder
] )
Parameters
fileURI
A string specifying the file to be added to the project, expressed as a file:/// URI.
autoCreateFolder
An optional Boolean value specifying if folders should be automatically
created in the Project panel to mirror the path in
fileURI
; the default value is
false
.
Returns
If successful, returns a ProjectItem object; otherwise, returns
undefined
. See
ProjectItem
object
.
Description
Method; adds the specified file to the project. You can use
autoCreateFolder
to determine
where the new file should be positioned in the Project panel:
■
If you omit
autoCreateFolder
or pass a value of
false
, the file is added at the root level
of the project.
■
If you pass a value of
true
for
autoCreateFolder
, and
fileURI
is below the FLP file in
the folder structure on disk, the folder structure of the files is mirrored in the Project
panel. That is, new folders are added to the Project panel if necessary to reflect the
location of the file on disk.
■
If you pass a value of
true
for
autoCreateFolder
, and
fileURI
is above the FLP file in
the folder structure on disk, the file is added at the root level. That is,
autoCreateFolder
is ignored.
Summary of Contents for FLASH 8-EXTENDING FLASH
Page 1: ...Extending Flash...
Page 38: ...38 Top Level Functions and Methods...
Page 532: ...532 Objects...
Page 554: ...554 C Level Extensibility...