Chapter 22. Working with Data Entry Forms
IN THIS CHAPTER
Using the
Form
containerCreating a
Form
componentLaying out
Form
controls with theFormItem
containerValidating data entry
Sharing data with value objects and custom events
When you start to integrate data into a Flex application, you have to solve the problem of how to get data into the Flex runtime environment. As you have seen in earlier chapters, you can embed data into the application using hard-coded MXML or ActionScript, or by integrating data into the application with the <fx:Model>
tag. These strategies, however, only work for data that's both small and static.
For existing data that's retrieved from a server-based resource, such as a database or an EXtensible Markup Language (XML) file, you can use Remote Procedure Call (RPC) components such as HTTPService, WebService
, and RemoteObject
.
Note
For more information about HTTPService, WebService
, and RemoteObject
RPC components, see Chapters 23, 25, 26, 28, and 29.
And then there's data that comes from the user. Unless an application is used exclusively with static data or content retrieved from a server at runtime, a data-centric application must collect data from the user. In this chapter, I describe using the following tools for building data entry form components:
The
Form, FormHeading
, andFormItem
components for laying out a data entry formValidator
components to validate a user's data entryCustom value object and event classes to share data with the rest of the application ...
Get Flash® Builder™ 4 and Flex® 4 Bible now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.