You can create or remove selections.
This example creates and removes selections.
| JavaScript |
Copy Code
|
|---|---|
window.onload = function() { var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"),{sheetCount:3}); var activeSheet = spread.getActiveSheet(); activeSheet.setColumnCount(5); $("#button1").click(function() { // Select entire row 4. activeSheet.addSelection(3, -1, 1, -1); }); $("#button2").click(function() { // Remove the selections in the sheet. activeSheet.clearSelection(); }); } |
|