|
SYS-CON.TV Webcasts
Comments
Did you read today's front page stories & breaking news?
SYS-CON.TV
|
Top Links You Must Click On
CF & Flex My First Flex Application
For this article I used Flex 2 beta3. Since then Flex 2 has been released so you should download that
By: Mary McDonald
Aug. 29, 2006 10:00 AM
We'll walk through the following steps to write our first Flex application.
When you set out to write your first Flex application you'll have to choose what tool you'll use to write it with. Currently the most popular tool to use is the free Eclipse IDE. If you don't have Eclipse installed go to http://www.eclipse.org/ to install it. You'll need to install Eclipse 3.1 to use Flex 2 Beta 3.
Select the Downloads link Eclipse can be used with many operating systems. I'll be using Windows XP with the Sun Java 2 Standard Edition Platform version 1.4.2_08 for Microsoft Windows. See the Eclipse readme_eclipse.html for more information. There are various plug-ins available for Eclipse. There's a Flex plug-in we'll install so we can use Eclipse to write our Flex app. The Eclipse plug-in for Flex is included in the Flex download. Go to http://labs.adobe.com/ to download the Flex 2.0 Beta 3. Open the Eclipse IDE by clicking the Eclipse icon. Eclipse will ask you where you want your workspace to be located. Just leave it in the default directory for now. Press OK. We have to install the Flex Plug-in into Eclipse. I downloaded the Flex Builder 2 Beta 3 and selected the install option. I'll choose the Flex Builder plug-in and Flex SDK option to install Flex Builder as an Eclipse plug-in. Press the Unpack button to unpack to a temporary installation area. Press the Next button. Accept the license. Accept the default directory to install the Flex Framework. The My Eclipse folder is in my desktop, so that's where I installed the Flex plug-in. After you press OK, the path to the Eclipse plug-in is entered. Press Next. You'll have to install Flash Player 9.0 to view applications developed with Flex 2 for the browser of your choice. Check your pre-installation summary to verify that everything is correct then press the Install button. Once installed, you'll get a message that the software has been successfully installed. Open the Eclipse program. Make a note of the default workspace where Eclipse will be looking for your applications or choose a directory where you want Eclipse to look for your applications. To verify that the Flex Builder 2 Beta 3 plug-in was installed, select Help/Software Updates/Manage Configurations. You should see the Flex Builder 2 Beta 3 plug-in zorn.feature.core 2.0.340. Open a new project in Eclipse. Under Flex, select Flex Project and press the Next button. We won't use any Flex server technology for this application, so select the Basic radio button and press the Next button. Name the project and press the Finish button. I called mine MyFirstFlex2Beta3App. Enter the Flex Builder 2.0 serial number or select Try to try Flex Builder. Select OK to switch to the Flex Development Perspective. Flex defaults to the Source view. Select the Design tab to switch to the Design view. In the Design view locate the Panel component under the Components tab on the lower left and drag the Panel to the stage. In the Flex Properties tab on the lower right, type in myPanel next to the id field under the General area. Next, locate the ControlBar component on the lower left and drag it to the bottom of the Panel. Next to the id in the Flex Properties type myControlBar in the General area. Locate the Button component under the Controls folder on the lower-left Components tab. Drag the Button component and put it over the ControlBar component. Reader Feedback: Page 1 of 1
Your Feedback
Enterprise Open Source Magazine Latest Stories . . .
Subscribe to the World's Most Powerful Newsletters
Subscribe to Our Rss Feeds & Get Your SYS-CON News Live!
|
SYS-CON Featured Whitepapers
Most Read This Week |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||