Im using dhtmlxlayout 3.5. I try to resize my layout to the size of the attached grid like this.
grid = dhtmlxlayout.cells(“a”).attachGrid();
//load data to grid
…
dhtmlxlayout.cells(“a”).setHeight(grid.ent.offsetHeight);
This somehow doesnt work. However, if i manually set height for each parent node of the grid then it works.
var parent = $(‘.objbox’).parent();
while (parent) {
parent.height(iGrid.entBox.offsetHeight + 30);
if (parent.attr(“id”) == “div_container”)
break;
parent = parent.parent();
}
Is there any better way to do this?