Spread.Sheets Documentation > Sample Code > Sample Code for Cells > Getting the Active Cell Index |
You can get the index of the active cell.
This example gets the column and row index of the active cell.
JavaScript |
Copy Code
|
---|---|
$("#button1").click(function () { var sheet = spread.getActiveSheet(); alert("Row index of an active cell : " + sheet.getActiveRowIndex() + "\n" + "Column index of an active cell: " + sheet.getActiveColumnIndex()); }); |