"EnableEmptyListItem" with RadComboBox

4 posts, 0 answers
  1. Jacek
    Jacek avatar
    12 posts
    Member since:
    Apr 2011

    Posted 15 Nov 2013 Link to this post

    How to implement "EnableEmptyListItem" functionalityn in RadComboBox, just like in dropdown included with RadGrid?
  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 15 Nov 2013 Link to this post

    Hi Jacek,

    You can set the EmptyMessage property of the RadComboBox.

    ASPX:
    <telerik:RadComboBox ID="RadComboBox1" runat="server"  EmptyMessage="..Select.."  . . . .>
    </telerik:RadComboBox>

    Thanks,
    Princy
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Jacek
    Jacek avatar
    12 posts
    Member since:
    Apr 2011

    Posted 15 Nov 2013 Link to this post

    Hey, Princy,

    answer is not so simple, because cb is connected to database and user should be able to update value with "null".
    Now I am using below method, but I was trying to find something similar to RadGrid DropDown "EnableEmptyListItem" .

    <telerik:RadComboBox ID="cb1" Runat="server" DataSourceID="ds1" DataTextField="CODE" DataValueField="ID" AppendDataBoundItems="True" >
                            <Items>
                                <telerik:RadComboBoxItem runat="server" Text="..." Value="null" />
                            </Items>
                        </telerik:RadComboBox>
  5. Nencho
    Admin
    Nencho avatar
    1458 posts

    Posted 20 Nov 2013 Link to this post

    Hello Jacek,

    I would suggest you to use the Default Item of the RadComboBox. Here you could find our documentation article regarding the usage of the Default Item. Please note, that it could be implemented only in a readonly RadComboBox scenario.

    Regards,
    Nencho
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Back to Top