Container Flex



    xmlns:s="library://ns.adobe.com/flex/spark"
    xmlns:mx="library://ns.adobe.com/flex/mx">
    
         
        import mx.events.ItemClickEvent; 
        import mx.controls.TabBar; 
        import mx.collections.ArrayCollection; 
        [Bindable] 
        private var STATE_ARRAY:ArrayCollection = new ArrayCollection([ 
            {label:"Alabama", data:"Montgomery"}, 
            {label:"Alaska", data:"Juneau"}, 
            {label:"Arkansas", data:"LittleRock"} 
        ]); 
        private function clickEvt(event:ItemClickEvent):void { 
            // Access target TabBar control. 
            var targetComp:TabBar = TabBar(event.currentTarget); 
            forClick.text="label is: " + event.label + "\nindex is: " + 
                     event.index + "\ncapital is: " + 
                     targetComp.dataProvider[event.index].data; 
        } 
      
    

    
        
            {STATE_ARRAY}