:: Forum >>

initial row selections

hi,

the code below does result in a table with highlighted first row (no selection highlight is shown at all). What am I doing wrong?


<script>
var table = new AW.UI.Grid;
table.setRowCount(4);
table.setColumnCount(4);
table.setCellText( function(i,j) {return i+j} )
table.setSelectedRows([0]);
document.write(table);
</script>


thanks
Dmitry
Wednesday, January 4, 2006
Dmitry,

I had the same issue. For reasons I'm not sure, the the entire grid needs to be finished loading to set the first row active. I found that if I called an onLoad function from the <body> tag, it would execute after the grid was finished loading.

<script>
function highlightRow() {
obj.setSelectedRows([0]);
}
</script>

<body onLoad=highlightRow()>
...
</body>

Sam S.
Monday, January 9, 2006

This topic is archived.


Back to support forum

Forum search