AllowCustomText Behavior for Non-List Items

3 posts, 0 answers
  1. ColinBowern
    ColinBowern avatar
    51 posts
    Member since:
    Aug 2012

    Posted 14 Jan 2010 Link to this post

    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.


    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. Kalina
    Kalina avatar
    918 posts

    Posted 15 Jan 2010 Link to this post

    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?

    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.
  3. ColinBowern
    ColinBowern avatar
    51 posts
    Member since:
    Aug 2012

    Posted 15 Jan 2010 Link to this post

    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. 

Back to Top