Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by kunal on Nov 11, 2008 03:58
open dhtmlx forum
how to check whether check box is checked

hello,

I am using custom xml format to load dhtmlx grid..

I have used mygrid.parse("xmlstring","xmlB"); api...in my code.

there in my code .. I have specified the columntype as checkbox...
for eg.

mygrid.setColTypes("ed,co,ed,ch,ed,ed,co");

Now the check box is appeared in my grid...

So please tell me how do I check whether the checkbox is checked or not..?

is there any event like onclick event for such checkbox?

suggest me any provision to give javascript function on related event of that checkbox..


Answer posted by Support on Nov 11, 2008 04:03
>>So please tell me how do I check whether the checkbox is checked or not..?
Get all checked in some column
   grid.getCheckedRows(index);
Get state of specific cell
   grid.cells(i,j).isChecked()

>>is there any event like onclick event for such checkbox?
In case of dhtmlxgrid - there is onCheckbox event, called each time when checkbox state changed