This is a migrated thread and some comments may be shown as answers.

Combobox behavior - IsEditable and not ReadOnly

1 Answer 94 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Kakone
Top achievements
Rank 1
Kakone asked on 17 Jan 2011, 05:49 PM
Hello,

I don't understand the behavior of an editable and not readonly combobox. The Text property value can be different than the corresponding SelectedItem. Why ?
For example, with your demo (configurator), I typed 'pa' then I delete the 'a' character. Why the 'Pavlova' agency is still selected ? (cf screenshot in attachment).

Other question:
I try to do an autocomplete combobox like in this blog:
http://blogs.telerik.com/valerihristov/posts/08-12-04/auto-complete_combobox_with_wcf_service_and_radcontrols_for_silverlight.aspx.
Althought it's not a readonly combobox, I would like to force the user to choose a value from the combobox. What is your suggestion to achieve this ?

Cordially,
Stephane.

1 Answer, 1 is accepted

Sort by
0
Boyan
Telerik team
answered on 20 Jan 2011, 06:22 PM
Hi Kakone,

Here is how it works. You have a property CanAutoCompleteSelectItems which is true by default for IsEditable RadComboBox. That is why the item is selected when autocomplete(note that this property works only if the drop down is opened) and if there are multiple items starting with the entered text it is always selecting the first one. That is why even when you delete the "a" you are still selected Pavlova(it is the first item starting with P). In order to clear the selection you have to delete the whole Text.

What exactly is your scenario? have you tried to use IsFiltering= true to filter the items.

All the best,
Boyan
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
Tags
ComboBox
Asked by
Kakone
Top achievements
Rank 1
Answers by
Boyan
Telerik team
Share this question
or