SheetModel

23 Sep 20252 minutes to read

Interface for a class Sheet

Properties

activeCell string

Specifies active cell within selectedRange in the sheet.

colCount number

Defines the number of columns to be rendered in the sheet.

columns ColumnModel[]

Configures column and its properties for the sheet.

conditionalFormats ConditionalFormatModel[]

Specifies the conditional formatting for the sheet.

frozenColumns number

Gets or sets the number of frozen columns.

frozenRows number

Gets or sets the number of frozen rows.

index number

Specifies index of the sheet. Based on the index, sheet properties are applied.

isProtected boolean

Specifies to protect the cells in the sheet.

name string

Specifies the name of the sheet, the name will show in the sheet tabs.

paneTopLeftCell string

Represents the freeze pane top left cell. Its default value would be based on the number of freeze rows and columns.

password string

Specifies the password.

protectSettings ProtectSettingsModel

Configures protect and its options.

ranges RangeModel[]

Specifies the collection of range for the sheet.

rowCount number

Defines the number of rows to be rendered in the sheet.

rows RowModel[]

Configures row and its properties for the sheet.

selectedRange string

Specifies selected range in the sheet.

<div id='Spreadsheet'></div>
let spreadsheet: Spreadsheet = new Spreadsheet({
     sheets: [{
               selectedRange: 'A1:B5'
         }],
     ...
});
spreadsheet.appendTo('#Spreadsheet');

showGridLines boolean

Specifies to show / hide grid lines in the sheet.

showHeaders boolean

Specifies to show / hide column and row headers in the sheet.

standardHeight number

Represents the standard height of the sheet.

state SheetState

Specifies the sheet visibility state. There must be at least one visible sheet in Spreadsheet.

topLeftCell string

Specified cell will be positioned at the upper-left corner of the sheet.

usedRange UsedRangeModel

Defines the used range of the sheet.