Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by richard white on Mar 20, 2009 08:13
open dhtmlx forum
hide column problems

hi,

we have a grid with several columns and have a menu bar which allows the user to show/hide any column they want.

however there is a bug appearing when we try to show / hide a column. this is the error (also the columns then do not appear level with the headers and the grid looks a mess):

this.rowsAr[i].childNodes[ind].style is undefined
collapseAll()(3, "none")dhtmlXTreeGrid.js (line 50)
_hideShowColumn()(3, "none")dhtmlxgrid.js (line 409)
setColumnHidden()(3, true)dhtmlxgrid.js (line 391)
showHideDoctorColumns("titleColumn", true, false)index.cfm (line 1963)
_renderSeparator()()dhtmlxmenu.js (line 37)
_renderSeparator()("oncheckboxclick", ["titleColumn", true, false 0=titleColumn 1=true 2=false])dhtmlxmenu.js (line 37)
_countPolygonItems()("titleColumn", "--n")dhtmlxmenu.js (line 25)
_renderToplevelItem()(click clientX=277, clientY=407)dhtmlxmenu.js (line 35)
[Break on this error] this.rowsAr[i].childNodes[ind].style.di...="blank";//(c)dhtmlx ltd. www.dhtmlx.com

do you know why this would occur

thanks
Answer posted by dhxSupport on Mar 20, 2009 08:53
What version of dhtmlxTreeGrid do you use? Could you please provide any kind of sample where we can reproduce this issue (you can send it directly to the support@dhtmlx.com).

Also to prevent header's mess you can add following code to the code init:

mygrid.attachEvent("onColumnHidden",function(ind){
  if (!_isFF) return; 
  mygrid.obj.border="1"
  window.setTimeout(function(){
  mygrid.obj.border="0"  
},1);