Categories | Question details Back To List | ||
Grid, height of div Hello, What is the right way to make the height of grid dependant from the number of rows? Actually I can put something like <div id="gridbox" width="400" height="200" style="background-color:white;overflow:hidden"></div> Then the height="200" can be ot too little ( and I get verical scroll ) or too big ( then I get white space ). If I use 100% I still have a scroll. Also would be nice if by adding a row the height of the grid could be changed. Is it possible to realize? Answer posted by dhxSupport on May 05, 2009 02:23 You can use enableAutoHeight(true) mode. Grid's container width will increase depend on the number of rows. You can find sample here http://dhtmlx.com/docs/products/dhtmlxGrid/samples/grids_manipulations/grid_auto_height.html Answer posted by Alexander on May 05, 2009 02:50 Thank you. It was what I searched indeed. It works just fine when I add row. But if I delete row i does not decrease the height. Answer posted by dhxSupport on May 05, 2009 04:48 This functionality was swithed off to increase grid perfomance. If you will delete a lot of rows from your grid while enableAutoHeight is on this can descrease grid perfomance. |