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

AllowCustomText Behavior for Non-List Items

2 Answers 50 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
ColinBowern
Top achievements
Rank 1
ColinBowern asked on 14 Jan 2010, 05:23 PM
My understanding of AllowCustomText is that I should be able to type "foo" in the combo box and tab out.  The value should stay there even if "foo" isn't contained in the list of values returned from the data source.  Is this correct?

<telerik:RadComboBox ID="SpecificLocation" runat="server" AccessKey="f" AllowCustomText="true" 
    CollapseAnimation-Type="None" EnableLoadOnDemand="true" EnableVirtualScrolling="true" 
    ExpandAnimation-Type="None" MaxHeight="200px" MaxLength="70" OnDataBinding="Location_DataBinding" 
    ShowMoreResultsBox="false" ShowToggleImage="false" Text='<%# Bind("Location") %>' 
    WebServiceSettings-Method="GetData" WebServiceSettings-Path="../DataService.aspx" 
    Width="100%" /> 

When I use the above setup and type "foo" in the list then tab to the next field the value I typed is lost.  The resulting combo box is empty.  The behaviour I want to simulate is simialr to the IE8/FF3 search box when it lists suggestions but doesn't force you to choose a particular suggestion.

Thoughts?

UPDATE: I continued to search and found a post talking about a similar objective but it still clears the entered text when I tab out of the box - including items that were a part of the list.  Still confused as to why it clears things when focus is lost.

2 Answers, 1 is accepted

Sort by
0
Kalina
Telerik team
answered on 15 Jan 2010, 04:08 PM
Hi ColinBowern,

To reproduce your problem and find the solution I took one of Telerik on-line examples for RadComboBox populated with data from web service (you can find it here).

I set the AllowCustomText property to true, typed some text and pressed the TAB key - the text didn't disappear. 

Additionally I tested the IE8/FF3 search box behavior and noticed that the text also remained there after pressing the TAB key.

At this point I can't reproduce your issue. Can you please take a look of aforementioned example and try to modify it so that the issue appears in it and provide the code? Which browser do you use?

Regards,
Kalina
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
ColinBowern
Top achievements
Rank 1
answered on 15 Jan 2010, 04:10 PM
Kalina - looks like it was an issue on our end.  There was a global javascript call that wired up to the combo box on blur event to cause the behavior. 

Thanks!
Colin
Tags
ComboBox
Asked by
ColinBowern
Top achievements
Rank 1
Answers by
Kalina
Telerik team
ColinBowern
Top achievements
Rank 1
Share this question
or