-
-
Notifications
You must be signed in to change notification settings - Fork 36
moveSheet
Julian Halliwell edited this page Jun 22, 2024
·
1 revision
Moves the named sheet to the specified new position.
moveSheet( workbook, sheetName, newPosition )
-
workbook
spreadsheet object -
sheetName
string: the name of the sheet to remove -
newPosition
integer: the new position the sheet should appear at within the work book
Chainable? Yes.
spreadsheet = New spreadsheet();
workbook = spreadsheet.workbookFromQuery( data );
spreadsheet.createSheet( workbook, "test" ); // create a second sheet
spreadsheet.moveSheet( workbook, "test", 1 ); // move the new sheet so it's the first sheet in the workbook