:: Forum >> Version 2 >>

Auto row height hide the last rows

Hello support team,

I use the Version 2.5.3 of the Grid and if I activate the auto height for the rows, the last rows of my grid will be hided. I can't scroll to the last row and the grid shows like truncated. I see that the grid has more rows, but the scrollbar is at the buttom and so I can't scroll to the last row.

If I delete the following code, all rows will be shown, but I need the auto row height to display the hole cell text for each row:
objGrid.getRowTemplate().setStyle("height""auto");  Do you have a solution for me?

Thanx
Alexander Hofmann from dacore Datenbanksysteme AG
Friday, June 19, 2009
I solved the problem with the following lines:

<body onresize="ResizeTable();" onload="ResizeTable();">

function 
ResizeTable()
{
var 
browseHeight
var 
browseWidth
browseHeight=document.body.clientHeight;
browseWidth =document.body.clientWidth;
objGrid.setSize(browseWidth -16browseHeight-200);
            
//recalculate the scrollbar size, because of the auto row property
var scrollHeight 0
var 
ScrollbarMultiplicator=0.0;
for (
0objGrid.getRowCount(); i++) { 
    
scrollHeight += objGrid.getRowHeight(i); 
    } 
            
ScrollbarMultiplicator = (browseHeight-200)/1.49
ScrollbarMultiplicator = (browseHeight-200)/ScrollbarMultiplicator;
scrollHeight=scrollHeight*ScrollbarMultiplicator //ScrollbarMultiplicator=1.49; <-bei Window maximized und 1280 * 1024 
//set new scrollbarheight
objGrid.setScrollProperty('height',scrollHeight); 
objGrid.refresh(); 
        } 
I hope I can help somebody else, who has the same problem.
Alexander Hofmann from dacore Datenbanksysteme AG
Monday, June 22, 2009



This topic is archived.

Back to support forum

Forum search