7 Replies Latest reply on Aug 20, 2009 6:23 AM by csr_1978

    ComboBox with default item selected




      I am trying to display combobox with an item selected by default. Is it possible to use selectedItem instead of selectedIndex to acheive this?


      Here is the code and I want User2 to be selected by default:


      <?xml version="1.0" encoding="utf-8"?>
      <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" xmlns:local="*">
      <mx:HBox id="box">
          <mx:Label text="User:"/>
          <mx:ComboBox prompt="Select" selectedItem="User2">


      Please let me know if this is possible?