How to unselect the parent checkbox when their child checkbox is unchecked using Jquery? <p>I am using asp.net tree view control. And using Jquery to select all the corresponding child check box when its parent is checked. The working Jquery and the rendered HTML is in here...<a href="http://jsfiddle.net/srk1982/Gak2h/7/" rel="nofollow">JS Fiddle</a></p> <p>Jquery to select the checkbox :</p> <pre><code> $('.tree').on('change', ':checkbox', function () { var checked = this.checked; var $elem = $(this).closest('table'); var depth = $elem.find('div').length; var $childs = $elem.nextAll('table'); $childs.each(function () { var $child = $(this); var d = $child.find('div').length; if (d &lt;= depth) { return false; } $child.find(':checkbox').prop('checked', checked); }); }); </code></pre> <p>But I do not know how to unselect the parent node when one of its child item is checked. Help needed..</p>