how add a listener to a grid extjs

w add a listener to a grid extjs

var grid = new Ext.grid.GridPanel({
store: store,
cm: cm,
listeners: {
      cellclick: function(grid, rowIndex, colIndex) {
          if (colIndex > 0) {
              var rec = grid.store.getAt(rowIndex);
              rec.set('value', colIndex);
              //get value here from colindex+rowindex.
         }
      }
   }
});

0 pensamientos:

Post a Comment

feedback!