Adobe
Products
Acrobat
Creative Cloud
Creative Suite
Digital Marketing Suite
Digital Publishing Suite
Elements
Photoshop
Touch Apps
Student and Teacher Editions
More products
Solutions
Creative tools for business
Digital marketing
Digital media
Education
Financial services
Government
Web Experience Management
More solutions
Learning Help Downloads Company
Buy
Home use for personal and home office
Education for students, educators, and staff
Business for small and medium businesses
Licensing programs for businesses, schools, and government
Special offers
Search
 
Info Sign in
Welcome,
My cart
My orders My Adobe
My Adobe
My orders
My information
My preferences
My products and services
Sign out
Why sign in? Sign in to manage your account and access trial downloads, product extensions, community areas, and more.
Adobe
Products Sections Buy   Search  
Solutions Company
Help Learning
Sign in Sign out My orders My Adobe
Preorder Estimated Availability Date. Your credit card will not be charged until the product is shipped. Estimated availability date is subject to change. Preorder Estimated Availability Date. Your credit card will not be charged until the product is ready to download. Estimated availability date is subject to change.
Qty:
Purchase requires verification of academic eligibility
Subtotal
Review and Checkout
Adobe Developer Connection / Flash Developer Center / Components Learning Guide /

Components Learning Guide for Flash: Creating custom components

by Adobe

Adobe Flash

Modified

18 January 2011

Page tools

Share on Facebook
Share on Twitter
Share on LinkedIn
Bookmark
Print
components Flash Professional

Components are prebuilt controls (movie clips) that you can reuse within your Adobe Flash Professional projects. The components that ship with Flash Professional CS5 are designed to speed your development process, but you can also build your own. Custom components can be saved or installed into the Components panel and can appear in their own category.

To create a custom component in Flash Professional, simply right-click a movie clip symbol in the Library and choose the Component Definition option. The Component Definition dialog box (see Figure 1) allows you to add parameters and component features to a symbol. Doing so transforms the movie clip into a component with properties that can be configured in the Properties panel.

Component Definition dialog box
Figure 1. Component Definition dialog box showing the alpha property being exposed as a component parameter

To create a live preview and publish the custom component, right-click the component movie clip symbol and choose the Export SWC File option. Exporting the SWC saves a compiled version of the component and automatically generates a live preview. By default, Flash saves the SWC in the user Configuration folder which, in turn, makes the component appear as a reusable object in the Components panel. For more information on component architecture and SWC files, please see the Component architecture section of the Using ActionScript 3 Components online documentation.

Custom components can be simple or complex. Creating advanced component features requires ActionScript classes to generate component functionality and component metadata to generate parameters. The process for creating components using ActionScript 2 and ActionScript 3 is relatively similar; however, ActionScript 3 should be used whenever possible as a best practice.

For more information on building advanced component architectures, see Jeff Kamerer's series on creating ActionScript 3 components in Flash:

  • Part 1: Introducing components
  • Part 2: MenuBar component prototype
  • Part 3: From prototype to component
  • Part 4: Events
  • Part 5: Styles and skins
  • Part 6: Invalidation model
  • Part 7: Focus management
  • Part 8: Keyboard support
  • Part 9: Shim compiled clip

You can also create custom components for use in the Adobe Flex framework while developing in Flash Professional. For more information, please see the Working with Flash Pro and Flash Builder section of the Using Flash Professional online documentation.

You can package components saved as SWC files using the Adobe Extension Manager. The Extension Manager enables you to create and install MXP or ZXP files as an easy way to distribute extensions for Flash Professional as well as other products in the Adobe Create Suite. For more information, please see the Using Adobe Extension Manager CS5 online documentation.

Creative Commons License
This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License

More Like This

  • Components Learning Guide for Flash: Examining ActionScript 3 components
  • Components Learning Guide for Flash: Examining ActionScript 2 components

Products

  • Acrobat
  • Creative Cloud
  • Creative Suite
  • Digital Marketing Suite
  • Digital Publishing Suite
  • Elements
  • Mobile Apps
  • Photoshop
  • Touch Apps
  • Student and Teacher Editions

Solutions

  • Digital marketing
  • Digital media
  • Web Experience Management

Industries

  • Education
  • Financial services
  • Government

Help

  • Product help centers
  • Orders and returns
  • Downloading and installing
  • My Adobe

Learning

  • Adobe Developer Connection
  • Adobe TV
  • Training and certification
  • Forums
  • Design Center

Ways to buy

  • For personal and home office
  • For students, educators, and staff
  • For small and medium businesses
  • For businesses, schools, and government
  • Special offers

Downloads

  • Adobe Reader
  • Adobe Flash Player
  • Adobe AIR
  • Adobe Shockwave Player

Company

  • News room
  • Partner programs
  • Corporate social responsibility
  • Career opportunities
  • Investor Relations
  • Events
  • Legal
  • Security
  • Contact Adobe
Choose your region United States (Change)
Choose your region Close

North America

Europe, Middle East and Africa

Asia Pacific

  • Canada - English
  • Canada - Français
  • Latinoamérica
  • México
  • United States

South America

  • Brasil
  • Africa - English
  • Österreich - Deutsch
  • Belgium - English
  • Belgique - Français
  • België - Nederlands
  • България
  • Hrvatska
  • Česká republika
  • Danmark
  • Eastern Europe - English
  • Eesti
  • Suomi
  • France
  • Deutschland
  • Magyarország
  • Ireland
  • Israel - English
  • ישראל - עברית
  • Italia
  • Latvija
  • Lietuva
  • Luxembourg - Deutsch
  • Luxembourg - English
  • Luxembourg - Français
  • الشرق الأوسط وشمال أفريقيا - اللغة العربية
  • Middle East and North Africa - English
  • Moyen-Orient et Afrique du Nord - Français
  • Nederland
  • Norge
  • Polska
  • Portugal
  • România
  • Россия
  • Srbija
  • Slovensko
  • Slovenija
  • España
  • Sverige
  • Schweiz - Deutsch
  • Suisse - Français
  • Svizzera - Italiano
  • Türkiye
  • Україна
  • United Kingdom
  • Australia
  • 中国
  • 中國香港特別行政區
  • Hong Kong S.A.R. of China
  • India - English
  • 日本
  • 한국
  • New Zealand
  • 台灣

Southeast Asia

  • Includes Indonesia, Malaysia, Philippines, Singapore, Thailand, and Vietnam - English

Copyright © 2012 Adobe Systems Incorporated. All rights reserved.

Terms of Use | Privacy Policy and Cookies (Updated)

Ad Choices

Reviewed by TRUSTe: site privacy statement