SpreadJS Documentation > Sample Code > Sample Code for Frequently Used Events > Using Events when Moving a Cell |
You can use events when moving a cell.
This example uses the LeaveCell event.
JavaScript |
Copy Code
|
---|---|
var spread = new GcSpread.Sheets.Spread($("#ss").get(0),{sheetCount:3}); var activeSheet = spread.getActiveSheet(); activeSheet.bind(GcSpread.Sheets.Events.LeaveCell, function (sender, args) { console.log("The column index before moving: " + args.col); console.log("The row index before moving: " + args.row); }); |