CustomActions.install()
Availability
Flash Player 6.
Usage
CustomActions.install(customName:String, customXML:String) : Boolean
Parameters
The name of the custom action definition to install.
customName
The text of the XML definition to install.
customXML
Returns
A Boolean value of
returned to indicate that the custom action has been successfully installed.
Description
Method; installs a new custom action XML definition file indicated by the
parameter. The contents of the file is specified by the string
The name of the definition file must be a simple filename, without the .xml file extension, and
without any directory separators (':', '/' or '\').
If a custom actions file already exists with the name
If the Configuration/ActionsPanel/CustomActions directory does not exist when this method is
invoked, the directory is created.
Example
The following example installs information into the Actions panel from an XML file. Open a text
editor and save a new document called dogclass.xml. Enter the following code:
<?xml version="1.0"?>
<customactions>
<actionspanel>
<folder version="7" id="DogClass" index="true" name="Dog" tiptext="Dog
Class">
<string version="7" id="getFleas" name="getFleas" tiptext="gets number
of fleas" text=".getFleas(% fleas %)" />
</folder>
</actionspanel>
<colorsyntax>
<identifier text=".getFleas" />
</colorsyntax>
<codehints>
<typeinfo pattern="*_dog" object="Dog"/>
</codehints>
</customactions>
if an error occurs during installation; otherwise, a value of
false
.
customXML
, it is overwritten.
customName
CustomActions.install()
is
true
customName
233
Need help?
Do you have a question about the FLASH MX 2004-ACTIONSCRIPT LANGUAGE and is the answer not in the manual?