开发者

javascript to select all checkbox in gridview

i 开发者_开发问答am searching for the javascript that performs select all - deselect all feature in asp.net gridview.

So if a header checkbox is selected all the item templates checkbox should be selected. if any item template checbox is deselcted, the header checkbox should also be deselected.

Thanks


$('#GridView1 input[type=checkbox]').each(function(){
this.checked=!this.checked;});

Add this on 'select all' button click

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜