Skip to content
Julian Halliwell edited this page Apr 8, 2017 · 8 revisions

Shifts one or more columns to the left or right.

shiftColumns( workbook, start [, end [, offset ] ] )

Required arguments

  • workbook spreadsheet object
  • start numeric: The number of the first, or only, column to shift.

Optional arguments

  • end numeric: The number of the last column to shift. If omitted the function shifts a single column.
  • offset numeric default=1: The positive (right) or negative (left) number of columns to shift by. If omitted the function shifts the column right by one.

Example

spreadsheet = New spreadsheet();
workbook = spreadsheet.new();
spreadsheet.addColumn( workbook,"a,b" );
spreadsheet.addColumn( workbook, "c,d" );
spreadsheet.shiftColumns( workbook, 1, 1, 1 );
Clone this wiki locally