Categories | Question details Back To List | ||
dhtmlxLayout, dhtmlxGrid hi, i get the following error when resizing a grid cell after removing a grid object that has been attached to a layouts cell (that has been attached using layout.attachGrid() ). the grid is removed using the grid's destructor() method. the error is: win.grid.setSizes is not a function http://applications-dev.widder.at/inc/dhtmlx_v2/dhtmlxLayout/codebase/dhtmlxlayout.js Line 75 any idea how fix this? regards, alexander Answer posted by Support on Feb 05, 2009 05:54 Hello, Please add the following code after grid removing: dhxGrid = dhxLayout.cells("a").attachGrid(); ... dhxGrid.destructor(); // add dhxLayout.cells("a").grid = null; Answer posted on Feb 05, 2009 06:22 hi, i still get the error. call stack is: win.grid.setSizes is not a function
setText()()dhtmlxlayout.js (line 75)
setText()()dhtmlxlayout.js (line 75)
setText()()dhtmlxlayout.js (line 75)
setText()()dhtmlxlayout.js (line 75)
...
more detailed sourcecode:
function init()
...
mainLayout=new dhtmlXLayoutObject(document.body, '3W', 'dhx_black');
...
gridVar=mainLayout.cells('b').attachGrid();
...
function someFunction()
...
gridVar.destructor();
mainLayout.cells('b').grid = null;
mainLayout.cells('a').collapse(); --> ERROR HAPPENS WHEN THIS IS EXECUTED
mainLayout.cells('b').collapse(); mainLayout.cells('c').expand(); regards
Alexander Answer posted by Support on Feb 05, 2009 07:44 Right, please try this: gridVar.destructor(); mainLayout.cells("b").grid = null; mainLayout.cells("b").window.grid = null; Answer posted on Feb 05, 2009 07:46 PERFECT! WORKS!!! thanks & regards, alexander |