Chapter 26. Connecting Your Project to Live Data

IN THIS CHAPTER

  • Setting up a server

  • Changing the project type

  • Connecting to data services

  • Binding data to a component

Your design comp likely contained a representation of data. In your Catalyst project, you converted that representation into a data list and, with the help of the Design-time Data panel, displayed sample data. Now, you will be able to connect the project to live data, generated by the server.

Flex projects run entirely on the client's side; that is, they run in Flash Player through a Web browser or on a user's desktop via AIR. As they do not run on the server, they have no direct access to server-side resources such as databases.

In order for your application to display live data, you need a script running on the server that can communicate with the database, retrieve the desired data, format it appropriately, and send it to Flex.

You can write this script in any one of a number of languages and rely on varying technologies. Whether you or your developer is proficient in Adobe ColdFusion, PHP, Microsoft ASP.NET, Ruby on Rails, or almost any other server-side technology, you will be able to leverage it to get data into your Flex application.

Setting Up a Local Testing Server

A local testing server is a Web server installed on your personal computer that you can use to simulate live connections with the database. While there are quite a few steps involved with downloading, installing and configuring the server, the process is ...

Get Flash® Catalyst™ CS5 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.