:: Forum >>

Load Data acording Index and column

// create ActiveWidgets Grid javascript object
var obj = new Active.Controls.Grid;

// set number of rows/columns
obj.setRowProperty("count", 20);
obj.setColumnProperty("count", 5);

// provide cells and headers text
obj.setDataProperty("text", function(i, j){return myData[i][j]});
obj.setColumnProperty("text", function(i){return myColumns[i]});

// set headers width/height

//get data cell clicked and column 0
obj.setAction("click", function(src){window.status = myData[src.getItemProperty("index")][0];});

// write grid html to the page
Rafael Costa, Andrei Barbosa
Wednesday, January 31, 2007

This topic is archived.

Back to support forum

Forum search