apps-script-utils 2.1.1 Help

appendColumn

function appendColumn( target: GoogleAppsScript.Spreadsheet.Sheet | GoogleAppsScript.Spreadsheet.Range, values: unknown, options: Options | null | undefined = {} ): GoogleAppsScript.Spreadsheet.Sheet;

The values fill the column downwards: one value per row. A sheet is examined whole and the column is written from row 1; a range is examined only inside itself and the column is written on its rows, right of the last column of the range that holds data.

It is appendColumns with one column: the same guards, the same growth of the sheet when the result would not fit, and the same rule that a cell whose text starts with = becomes a formula.

Parameters

Parameter

Type

Description

target

GoogleAppsScript.Spreadsheet.Sheet \| GoogleAppsScript.Spreadsheet.Range

The sheet to append to, or the range to append within.

values

unknown

A single column: a flat array, one value per row.

options (optional) = {}

Options \| null \| undefined

afterFrozenColumns starts the write past the frozen columns when the data ends before them.

Returns

GoogleAppsScript.Spreadsheet.Sheet — the sheet, so calls can be chained.

Throws

Exception

Condition

IllegalArgumentException

no argument is passed.

InvalidSheetException

the first argument is neither a sheet nor a range.

TypeError

the values are not a flat array.

Examples

Appending to a sheet

const sheet = SpreadsheetApp.getActiveSheet(); appendColumn(sheet, ["status", "new", "new"]);

Appending within a range

const sheet = SpreadsheetApp.getActiveSheet(); appendColumn(sheet.getRange("A1:D3"), ["status", "new", "new"]);

See also

Source

src/appsscript/sheet/appendColumn.ts

23 September 2026

This documentation was generated with AI (Claude) from the library's source code.