Hello, all,
I'm using the latest release of ASP.NET Ajax controls, and I'm facing a rather strange situation on one RadComboBox.
Actually I have a project where a particular combo box need to be loaded with one item (the default item: just setting RadCombo1.Text="something"; is not enough, for me). When an user opens it, this default value needs to be highlighted, because user has to be able of typing something into it. It has, amongst others, the following properties...
Well, when I load it for the first time, "OnClientItemsRequested" fires twice; plus, and here's the strange behavior, at the first time the default value is correctly highlighted (this combo box is correctly filled with all values), but at the second time the cursor goes to the end of text. If I close it and re-open it, default value is correctly highlighted.
I already tried to set this combo box text with the item text and then selecting it on "OnClientDropDownOpened", with no success. I tried also to mimic "MarkFirstMatch" as explained here:
http://www.telerik.com/community/forums/aspnet/combobox/radcombobox-loadondemand-itemsrequested-firing-multiple-times.aspx
but, since I also need to highlight the text (so, EnableTextSelection="true"), I'd need to at least set an automatic postback on this control, what it's not ok for me, due to performance reasons.
Any hint?
Thank you!
Ciao,
Sabrina.
I'm using the latest release of ASP.NET Ajax controls, and I'm facing a rather strange situation on one RadComboBox.
Actually I have a project where a particular combo box need to be loaded with one item (the default item: just setting RadCombo1.Text="something"; is not enough, for me). When an user opens it, this default value needs to be highlighted, because user has to be able of typing something into it. It has, amongst others, the following properties...
- EnableLoadOnDemand="true"
- MarkFirstMatch="true"
- EnableTextSelection="true"
- AllowCustomText="true"
- OnClientDropDownOpening="OnClientDropDownOpening"
- OnClientDropDownOpened="OnClientDropDownOpened"
- OnClientDropDownClosed="OnClientDropDownClosed"
- OnClientItemsRequesting="OnClientItemsRequesting"
- OnClientFocus="OnClientFocus"
- OnClientItemsRequested="OnClientItemsRequested"
Well, when I load it for the first time, "OnClientItemsRequested" fires twice; plus, and here's the strange behavior, at the first time the default value is correctly highlighted (this combo box is correctly filled with all values), but at the second time the cursor goes to the end of text. If I close it and re-open it, default value is correctly highlighted.
I already tried to set this combo box text with the item text and then selecting it on "OnClientDropDownOpened", with no success. I tried also to mimic "MarkFirstMatch" as explained here:
http://www.telerik.com/community/forums/aspnet/combobox/radcombobox-loadondemand-itemsrequested-firing-multiple-times.aspx
but, since I also need to highlight the text (so, EnableTextSelection="true"), I'd need to at least set an automatic postback on this control, what it's not ok for me, due to performance reasons.
Any hint?
Thank you!
Ciao,
Sabrina.