I'm having a problem with combobox doing an AutoComplete (ie markfirstmatch="true") when the cases don't match, and there are similar selection values. For example:
<
telerik:RadComboBox
ID
=
"RadComboBox1"
runat
=
"server"
AllowCustomText
=
"True"
MarkFirstMatch
=
"True"
>
<
Items
>
<
telerik:RadComboBoxItem
runat
=
"server"
/>
<
telerik:RadComboBoxItem
Text
=
"PAY"
Value
=
"PAY"
/>
<
telerik:RadComboBoxItem
Text
=
"PAYB"
Value
=
"PAYB"
/>
</
Items
>
</
telerik:RadComboBox
>
<
asp:Button
ID
=
"Postback"
runat
=
"server"
Text
=
"Post"
OnClick
=
"Postback_Click"
/>
<
asp:Label
ID
=
"Label1"
runat
=
"server"
Text
=
""
></
asp:Label
>
protected void Postback_Click(object sender, EventArgs e)
{
Label1.Text = RadComboBox1.Text;
}
When tabbing into the field (not clicking) so that the drop down does not open up, you try to type "PAYB", but in lower case. As you type, the box starts to find "PAY", but then when you type the last "b", the result is "PAYb". It does not find PAYB as expected.
What's even more concerning is that tabbing out and posting back, the combobox's text property is set to "PAY". (See screenshot attachments).
I've tried some possible solutions. I've tried using the Filter property. That works well when the drop down is opened, but when it is closed (ie tabbed into the field), you lose the AutoComplete functionality.
Is this solvable without using some javascript? If not, would doing some javascript to change lowercase to uppercase as the user types work? I'm not very well versed with javascript, so I don't know how that would look.
Thanks for the help!
10 Answers, 1 is accepted

I tried using some javascript to solve the problem. My first idea was to change the text from lower to upper case as the user types. I did this by using the OnClientKeyPressing event and checking the window.event.keyCode value. This doesn't work because the keyCode only ever sees the uppercase value (not sure if this is a javascript thing or ComboBox thing).
The next thing I tried was to change the value to upper case on OnClientTextChange. This fails because the javascript only sees the "PAY" value and not the entire "payb" as typed (from previous example).
I'm out of ideas at this point. I've submitted this as a bug in the Issue Tracker.
As I've mentioned in the support ticket you have submitted, this behavior is due to a bug, which is reproduced in IE7 and IE8.
If we came up with a workaround for it, you will be notified.
Kind regards,
Dimitar Terziev
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Could you specify which version of the controls you are using?
Greetings,
Dimitar Terziev
the Telerik team
Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!


If I recall correctly, when researching this issue, after browsing and searching for hours, I did not find a solution to this and ended up implementing my own (removing and adding items to the combobox manually OnKeyUp).
In retrospect, I wish I had just gone with the jquery autocomplete. You can find it here:
http://jqueryui.com/demos/autocomplete/

Thanks for the quick reply! I've got a lot of RadComboBoxes and code behind plumbing to pull out and replace with a jQuery solution but it's looking like I might not have a choice. Thanks for the link!
James
Please try to upgrade to the latest version of the controls if possible, and let me know whether the problem persists.
Greetings,
Dimitar Terziev
the Telerik team

Thanks
In case you experience problems with the ComboBox from our MVC suite, than it's better to post your query in their forum since this one is for RadControls for ASP.NET Ajax.
All the best,
Dimitar Terziev
the Telerik team