Hi 

<?xml version="1.0"?>
<!-- Simple example to demonstrate the ComboBox control. -->
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml";>

    <mx:Script>
        <![CDATA[

            [Bindable]
            public var cards: Array = [ {label:"Visa", data:1}, 
                {label:"Master Card", data:2}, {label:"American 
Express", data:3} ];
        
            [Bindable]
            public var selectedItem:Object;        
        ]]>
    </mx:Script>

    <mx:Panel title="ComboBox Control Example" height="75%" width="75%" 
        paddingTop="10" paddingLeft="10">

        <mx:HBox>
            <mx:ComboBox dataProvider="{cards}" width="150" 
                change="selectedItem=ComboBox
(event.target).selectedItem"/>

            <mx:VBox width="250">
                <mx:Text text="Select a type of CreditCard." 
width="200"/>
                <mx:Label text="You selected: {selectedItem.label}"/>
                <mx:Label text="Data: {selectedItem.data}"/>
            </mx:VBox>         
        </mx:HBox>
    </mx:Panel>
    
</mx:Application>


Check the about applicaiton.

Regards
Joshi Pattabhi
Hyperion Technologies (Flex Team)


-- In [email protected], "willmorganuk" <[EMAIL PROTECTED]> wrote:
>
> Hi All,
> 
> Any idea how I can add the usual "Select An Item" as the first label
> to a comboBox? The labels are from a webservice and I'm using
> lableField="GAL_NAME" so there isn't one available to me. How do I add
> that into the dataProvider?
> 
> Any help appreciated. Thanks, Will.
>






------------------------ Yahoo! Groups Sponsor --------------------~--> 
You can search right from your browser? It's easy and it's free.  See how.
http://us.click.yahoo.com/_7bhrC/NGxNAA/yQLSAA/nhFolB/TM
--------------------------------------------------------------------~-> 

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to