Multiselect - Removing Selected Data Items from dropdown list

2 posts, 0 answers
  1. Joey
    Joey avatar
    5 posts
    Member since:
    Apr 2016

    Posted 08 Sep Link to this post

    Is there anyway to remove the items that have been selected from the dropdown list already?  For instance, the multiselect functionality changed somewhere between 2014 - 2016.  The list used to only show items that were not already selected.  Now it shows all items and it shows items that have already been selected by highlighting them.  Is there an option to make it hide the selected items from list?  What was the reasoning behind changing the functionality?
  2. Nencho
    Admin
    Nencho avatar
    1458 posts

    Posted 12 Sep Link to this post

    Hello Joey,

    In order to achieve the desired behavior you can simply apply the following css style rule, and add the class to the MultiSelect widget:

      .hide-selected > li.k-state-selected {
                display: none;
            }
     
    ...
     
    <script>
        $(document).ready(function () {
            var multiselect= $("#required").data("kendoMultiSelect");
            multiselect.ul.addClass('hide-selected');
    </script>


    Regards,
    Nencho
    Telerik by Progress
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for ASP.NET MVC is VS 2017 Ready
Back to Top