We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

DropDownList selected items display

Hello.

Is it possible to display number of selected items instead of threir enumeration? For example: when selecting items  I want to display "10 of 30 items selected" instead of "item1,item2,item3....".

Thank you.

1 Reply

KC Kasithangam C Syncfusion Team June 17, 2015 01:15 PM UTC

Hi Bruce,

Thanks for using Syncfusion Products,

We have achieved your requirement “want to display "10 of 30 items selected” in the following sample and please find the sample under the following location.

Sample Location:Dropdown Sample

In the above sample, we have displayed the No. of dropdown items selected in the button click.Please find the code for same,

<code>

function click() {

        var DropDownListObj = $("#bikeList").data("ejDropDownList");

        var item = DropDownListObj.element.val();

        alert(item.split(",").length +"  of " + DropDownListObj.listitems.length + " items selected");

    }

</code>
Please let us know if you need further assistance.

Regards,

Kasithangam


Loader.
Live Chat Icon For mobile
Up arrow icon