Accessibility
Jen deHaan

Jen deHaan

Adobe
flashthusiast.com

Table of Contents

Created:
31 January 2005
User Level:
Intermediate
Products:
Flash

Binding Data Between Components Using the Data Binding Classes

Many of you have probably discovered how useful the Bindings tab in the Component Inspector panel can be. In case you haven't, you can use the Bindings tab to bind data between components on the Stage. This process is briefly demonstrated in this article, and in more detail within the following articles:

I also cover data bindings in my article, Building a Tip of the Day Application (Part 2): Working with Web Services.

What you might not have tried yet is creating bindings between components using simple ActionScript instead of the Bindings tab. Adding code is often faster and more efficient than relying on the authoring environment. This article introduces you to runtime data binding, and demonstrates how to create bindings using code instead of depending on the Component Inspector and several dialog boxes.

Requirements

Flash MX 2004 or Flash MX Professional 2004

Prerequisite knowledge:

Basic knowledge of the Flash authoring environment and a basic knowledge of ActionScript.

About the author

Jen deHaan was raised by wolves in the deep woods of the Canadian north. Later in life, Jen worked with Flash as a deseloper, then wrote about Flash for five versions, and then worked on stuff that didn't include much Flash. She came to her senses in 2007 by rejoining the fabled Flash team at Adobe as a QE, focusing on the good stuff—Motion (on timelines). Jen enjoys long walks in the rain pondering how many times she can use the word Flash in a bio, and admits that after numerous years in California she is no longer addicted to Tim Horton's coffee.