Search code examples
javascriptjqueryjqxgridjqxwidgets

jQuery and jqxGrid - how to select all rows in jqxGrid via checkboxes


How can I check all rows of jQWidgets jqxGrid with checkbox options programmatically‎? I can loop through rows and select them one-by-one or use

$("#jqxgrid").jqxGrid('selectallrows');

but I need to make a selection via the checkbox option - see

http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxgrid/index.htm?%28arctic%29#demos/jqxgrid/checkboxselection.htm

Basically I need to replicate a click on the top "Select All" checkbox.

How can I do this?

Thanks!


Solution

  • The solution is:

    $('#jqxGrid').jqxGrid('selectallrows');