you can add the following attribute:

prompt="Please select..."

That will be the first option in your combo.

--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> What do you want to happen?
> 
>  
> 
> ________________________________
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of srikanth_reddy_007
> Sent: Wednesday, November 14, 2007 8:01 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] how to Avoid - Compbo box fills up the first item
> when databinding is used
> 
>  
> 
> About Combobox filling up the first item by default when we databinding
> 
> I don't get what you mean to say ...
> 
> I have the code like this
> 
> <mx:ComboBox id="txtFamilyName"
> y="24" left="10" right="10" editable="true"
> focusIn="fetchAutoCompleteData(event, 'Family')"
> dataProvider="{modelLocator.searchModel.family}"
> focusOut="foucusOutHandler()"/>
> 
> in fetchAutoCompleteData function i will connect to database and
> update modelLocator.searchModel.family variable which has a
> databinding to ComboBox dataprovider. then the combobox will get
> populated with the first item of modelLocator.searchModel.family array
> . How can i avoid this?
> 
> and secondly the combobox grows its size to the max item fetched in
> the array. how can i avoid that too.
> 
> Thanks,
> Srikanth
>


Reply via email to