Adding Items on Client Side

4 posts, 0 answers
  1. Mark
    Mark avatar
    10 posts
    Member since:
    Jul 2013

    Posted 15 Jul 2013 Link to this post

    Is there an example anywhere that shows how to add new items on the client side to the dropdown list?

    The documentation seems to be lacking any examples really for the dropdowns client side.
  2. Mark
    Mark avatar
    10 posts
    Member since:
    Jul 2013

    Posted 15 Jul 2013 Link to this post

    I found the code in the template section for adding a item on the client side.  The code however seems to be incorrect because there is no Telerik.Web.UI.RadDropDownListItem()  but rather Telerik.Web.UI.DropDownListItem().

    Also the RadDropDownListItemCollection does not even state that the Add method exists?

  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 16 Jul 2013 Link to this post

    Hi Mark,

    Please have a look at the following code I tried to add a RadDropDownList item from client side.

    <script type="text/javascript">
        function addItem() {
            var raddropdownlist = $find('<%=RadDropDownList1.ClientID %>');
            var dropdownItem = new Telerik.Web.UI.DropDownListItem();

  5. Nencho
    Nencho avatar
    1458 posts

    Posted 18 Jul 2013 Link to this post

    Hello Mark,

    Your observations are absolutely correct. Thank you for your pointing that out. I have already fixed the mentioned inaccuracy in our documentation articles and they will be updated soon. As a token of gratitude, I have updated your Telerik Points.

    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