Problems with v2 beta 3 - grid.setAction

setAction property is not supported under v2 beta3.
Could anyone tell me what can be used instead?
December 9,
Can you tell us what you are trying to accomplish? Are you trying to associate a function with an event?
Jim Hunter
December 9,
I'm trying to collect some data from table1 when I click on a grid row. The code bellow works with the grid from v1.0, but gives "setAction property undefined" error when used with the grid from v2 b3. I'd appreciate any input. Here is the code:
var message = function(){
window.status = "Grid selection:" +
" latest=" + this.getSelectionProperty("index")

var id = table1.getData(this.getSelectionProperty("index"),3);
grid.setAction("selectionChanged", message);
December 9,
setAction and getAction methods are not used anymore in v.2 - instead you should assign your event/action handlers directly to the object using 'onEventName' syntax, for example

obj.onCellClicked = function(event, col, row){

You can find examples in /examples/quickref/grid.htm
Alex (ActiveWidgets)
December 9,
This works too:
obj.onRowClicked = function(event, index)
//Get the contents of cell with Column index '0' and RowIndex 'index'.
var id = obj.getCellValue(0, index);

December 9,

This topic is archived.

See also:

Back to support forum