LinkBar With Array Data
<?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical"> <mx:Script> import flash.net.navigateToURL; import mx.controls.Alert; import mx.events.ItemClickEvent; private function clickHandler(event:ItemClickEvent):void { var request:URLRequest=new URLRequest(event.item.url); navigateToURL(request); } </mx:Script> <mx:LinkBar itemClick="clickHandler(event)"> <mx:dataProvider> <mx:Object> <mx:label>Adobe</mx:label> <mx:url>http://www.adobe.com</mx:url> </mx:Object> <mx:Object> <mx:label>Google</mx:label> <mx:url>http://www.google.com</mx:url> </mx:Object> <mx:Object> <mx:label>Microsoft</mx:label> <mx:url>http://www.microsoft.com</mx:url> </mx:Object> </mx:dataProvider> </mx:LinkBar> </mx:Application>