Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Ben Leah on Oct 16, 2009 02:37
open dhtmlx forum
dhtmlxGrid, onHeaderClick

I have mulitple header rows in my grid, how do I get the row index in the onHeaderClick event?
Answer posted by Stanislav (support) on Oct 16, 2009 03:44
Event doesn't provide such info, you can try to access it by using dom properties

mygrid.attachEvent("onHeaderClick",function(index, e){
            var el = this.getFirstParentOfType(e.srcElement||e.target, "TR");
            var row_index = el.rowIndex; //here is it 
})