addArrayToSheet
On this page
Add an array-of-arrays to an existing worksheet, or create a new one.
Each inner array represents a row, and each element within it a cell value. Supports dense and sparse storage modes, origin offsets, date handling, and automatic type detection (number, boolean, string, date, error).
addArrayToSheet(worksheet: WorkSheet | null, data: any[][], opts?: AOA2SheetOpts): WorkSheet
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
worksheet | WorkSheet | null | Yes | An existing worksheet to append to, or null to create a new one |
data | any[][] | Yes | The array-of-arrays containing raw cell values |
opts | AOA2SheetOpts | No | Optional settings (origin, dense, dateNF, cellDates, UTC, date1904, nullError, sheetStubs) |
Returns
The updated or newly created worksheet