3.2.0

Vertical scrolling resets itself to top position after a second

I've got an Extended grid whose data is both wider and taller than the grid itself, so it displays with vertical and horizontal scrollbars. Scrolling horizontally works fine, but when I scroll vertically, the grid immediately jumps back to the top. Has anyone seen this problem before?

The code for my grid is this:

var obj = new AW.Grid.Extended;
obj.setId("myGrid");
obj.setFixedLeft(1);

var columnHeaders = <array of strings>;
obj.setColumnResizable(false, 0);
obj.setCellFormat(new AW.Formats.Number, 1);
obj.setColumnResizable(false, 1);
obj.setCellFormat(new AW.Formats.Number, 2);
obj.setColumnResizable(false, 2);
obj.setCellFormat(new AW.Formats.Number, 3);
obj.setColumnResizable(false, 3);
var totalRow = <array of strings>;
var data = <array of array of strings>;
obj.setRowCount(19);
obj.setColumnCount(4);

obj.setHeaderCount(2);
obj.setHeaderText(columnHeaders, 0);
obj.setHeaderText(totalRow, 1);
obj.setCellText(data);

obj.setStyle("width", "100%");
obj.setStyle("height", "300px");
obj.setSelectorVisible(false);
obj.setCellEditable(false);

document.write(obj);

Thanks!
Aaron Whittier
April 8,
Does it happen in IE, Firefox or both? Is your grid inside <table> tag? Are you using 2.0 final (not beta or RC)?
Alex (ActiveWidgets)
April 10,
This is in firefox 1.5.0.1, and the grid is inside a table. I am using the 2.0 final trial edition. If it helps, I have the FireBug extension (it reports javascript and css errors) and I'm not seeing any errors either during page load or when I attempt to scroll.
Aaron Whittier
April 11,
Try adding style="table-layout:fixed" to the <table> tag.
Alex (ActiveWidgets)
April 11,
That fixed it - thanks Alex!
Aaron Whittier
April 11,

This topic is archived.

See also:


Back to support forum