ActionScript extends the capabilities of Flex application developers. With ActionScript, you can define event listeners and handlers, get or set component properties, handle callback functions, and create new classes, packages, and components.
You can use ActionScript in your Flex applications in the following ways:
Insert ActionScript code blocks with the <mx:Script> tag. In these code blocks, you can add new functions, handle errors and events, and perform other tasks in your application or its supporting MXML files.
Call global ActionScript functions that are stored in the system_classes directory structure.
Reference external classes and packages in user_classes to handle more complex tasks. This lets you take advantage of ActionScript support for object-oriented programming concepts such as code reuse and inheritance.
Use standard Flex components. The logic of components and helper classes in the Flex application model is based on ActionScript classes.
Extend existing components with ActionScript classes.
Create new components in ActionScript.
Create new components in the Flash authoring environment (SWC files).