Paging 2.5
Alex
I have used the following code bit from you to develop paging in 2.02, it worked nice, but in 2.5 setRowOffset(x) start in the x row, meaning that the grid seams empty on page 2.
The reason why i can see this is offset is 32 but there is space enough to see 34, so page 2 only shows 2 rows in row 33 and 34.
Try your own example in version 2.5 and you will se the problem.
var obj = new AW.UI.Grid;
obj.setCellData(function(col, row){return col + "." + row});
obj.setHeaderText("header");
obj.setColumnCount(10);
obj.setRowCount(10);
document.write(obj);
document.write("<br>");
var button = new AW.UI.Button;
button.setControlText("Next");
document.write(button);
button.onControlClicked = function(){
var x = obj.getRowOffset();
obj.setRowOffset(x+10);
obj.refresh();
}
Alex Code from:
http://www.activewidgets.com/javascript.forum.12092.28/paging-with-version-2-0.html
I have used the following code bit from you to develop paging in 2.02, it worked nice, but in 2.5 setRowOffset(x) start in the x row, meaning that the grid seams empty on page 2.
The reason why i can see this is offset is 32 but there is space enough to see 34, so page 2 only shows 2 rows in row 33 and 34.
Try your own example in version 2.5 and you will se the problem.
var obj = new AW.UI.Grid;
obj.setCellData(function(col, row){return col + "." + row});
obj.setHeaderText("header");
obj.setColumnCount(10);
obj.setRowCount(10);
document.write(obj);
document.write("<br>");
var button = new AW.UI.Button;
button.setControlText("Next");
document.write(button);
button.onControlClicked = function(){
var x = obj.getRowOffset();
obj.setRowOffset(x+10);
obj.refresh();
}
Alex Code from:
http://www.activewidgets.com/javascript.forum.12092.28/paging-with-version-2-0.html
Armit
December 5,