How to create dynamically checkbox with knockout and kendo UI?

173 views
Skip to first unread message

Federico Croletti

unread,
Apr 7, 2017, 3:47:51 AM4/7/17
to KnockoutJS
It makes checkable only the first element
 I would like to click all the checkboxes also checking which I clicked

<div id="doc" data-bind="foreach: list"> 
        <input type="checkbox" id="field" class="k-checkbox">
        <label class="k-checkbox-label" for="field" data-bind="checked: myFunction,text: elem.name" checked></label>
        </div>

Michael Best

unread,
Apr 10, 2017, 2:53:39 PM4/10/17
to KnockoutJS
The checked binding needs to be on the <input> element, not the <label>
Reply all
Reply to author
Forward
0 new messages