adobe flex


Example 001: Building your first Flex application

Example 001: Building your first flex application. So the honest truth is, there is no better starting point than using the classic hello world project with your first flex application. MXML files are essentially XML files and which can be coded and updated in notepad or your favorite Flex compatible IDE. if you haven't already downloaded Flex 3 make sure you register and download your 30 day evaluation copy from adobe.com. The evaluation copy is a full blown version with several limitations (i.e. the graphics display a watermark, etc...). The following MXML file can be compiled using The flex application or by command-line using mxmlc.exe.

<?xml version="1.0" encoding="utf-8"?>

<mx:Application 
    xmlns:mx="http://www.adobe.com/2006/mxml" 
    viewSourceURL="src/HelloWorld/index.html"
    horizontalAlign="center" verticalAlign="middle" 
    width="300" height="160"
>
    <mx:Panel 
        paddingTop="14" paddingBottom="14" paddingLeft="14" paddingRight="14"
        title="My Application"  
    >

        <mx:Label text="Greetings World!" fontWeight="bold" fontSize="24"/>
    </mx:Panel>
</mx:Application>

To run the above MXML application:

1.) create a virtual directory in IIS.

2.) open flex and create a new flex
project. Under application server type, select asp.net.

3.) click finish

4.) double click on the newly created MXML file and copy in the above code.

5.) to run the application right-click on your new project/src/"name".mxml under Flex Navigator and select
run.