To add and configure a behavior:
1.
Select the object, such as a button, that will trigger the behavior.
2.
In the Behaviors panel (Window > Behaviors), click the Add (+) button and select the
desired behavior from the Movieclip submenu.
3.
In the dialog box that appears, select the movie clip that you want to control with the
behavior.
4.
Select a relative or absolute path.
For more information, see
on page
40.
5.
If required, select or input settings for the behavior parameters and click OK.
Default settings for the behavior appear in the Behaviors panel.
6.
Under Event, click On Release (the default event) and select a mouse event from the menu.
If you want to use the On Release event, leave the option unchanged.
Creating custom behaviors
You can write your own custom behaviors that serve your own needs. To do this, you create an
XML file that contains the ActionScript code needed to perform the desired behavior, and
save the file in the Behaviors folder of your local computer. Behaviors are stored in the
following location:
Windows: C:\Documents and Settings\user name\Local Settings\Application
Data\Macromedia\Flash 8\language\Configuration\Behaviors
Macintosh: Macintosh HD/Users/user name/Library/Application Support/Macromedia/
Flash 8/language/Configuration/Behaviors/
Before creating your own behaviors, examine the various Behavior XML files to develop an
understanding of the syntax of the XML files, as well as the ActionScript code used to create
behaviors. If you are new to writing behaviors, you should become familiar with the XML tags
used to create user interface elements (such as dialog boxes), and with ActionScript, the
coding language used to create behaviors. To learn about the XML used to create interface
elements, see
Appendix B, "XML to UI."
ActionScript 2.0 in Flash.
You can also download behaviors that other Flash users have created from the Macromedia
Exchange website. You can visit the Macromedia Exchange at:
mx/flash/
96
Using Symbols, Instances, and Library Assets
"About absolute paths" on page 39
To learn about ActionScript, see Learning
and
"About relative paths"
www.macromedia.com/devnet/
Need help?
Do you have a question about the FLASH 8-USING FLASH and is the answer not in the manual?
Questions and answers