Constructors
Section titled "Constructors"Workbook
new Workbook(): Workbook Returns Workbook
Properties
Section titled "Properties"$t: Type maxExcel2007CellFormatCount
Section titled "maxExcel2007CellFormatCount"maxExcel2007CellFormatCount: number maxExcel2007ColumnCount
Section titled "maxExcel2007ColumnCount"maxExcel2007ColumnCount: number maxExcel2007RowCount
Section titled "maxExcel2007RowCount"maxExcel2007RowCount: number maxExcelCellFormatCount
Section titled "maxExcelCellFormatCount"maxExcelCellFormatCount: number maxExcelColumnCount
Section titled "maxExcelColumnCount"maxExcelColumnCount: number maxExcelRowCount
Section titled "maxExcelRowCount"maxExcelRowCount: number maxExcelWorkbookFonts
Section titled "maxExcelWorkbookFonts"maxExcelWorkbookFonts: number Accessors
Section titled "Accessors"calculationMode
Section titled "calculationMode"Gets or sets the value which indicates how a formula will be recalculated when a referenced value changes.
get calculationMode(): CalculationMode
Returns CalculationMode
cellReferenceMode
Section titled "cellReferenceMode"Gets or sets the value which indicates the way cells in the workbook are referenced.
get cellReferenceMode(): CellReferenceMode
Returns CellReferenceMode
culture
Section titled "culture"Gets or sets the culture to use as the current culture for the workbook when doing any culture-aware conversions or comparisons.
get culture(): any
Returns any
set culture(a: any): void Parameters
- a:
any
Returns void
currentFormat
Section titled "currentFormat"Gets the current format of the workbook. This is the format which will be used when saving and imposing format restrictions.
get currentFormat(): WorkbookFormat
Returns WorkbookFormat
dateSystem
Section titled "dateSystem"Gets or sets the date system used internally by Microsoft Excel. The date system used internally by Microsoft Excel.
get dateSystem(): DateSystem
Returns DateSystem
defaultTableStyle
Section titled "defaultTableStyle"Gets or sets the default style for tables in the workbook.
get defaultTableStyle(): WorksheetTableStyle
Returns WorksheetTableStyle
documentProperties
Section titled "documentProperties"Gets the properties associated with the workbook document.
get documentProperties(): DocumentProperties
Returns DocumentProperties
editingCulture
Section titled "editingCulture"The editing culture affects certain language specific features such as formatting of dates. or comparisons.
get editingCulture(): any
Returns any
set editingCulture(a: any): void Parameters
- a:
any
Returns void
hasProtectionPassword
Section titled "hasProtectionPassword"Returns a boolean indicating if the Workbook has been protected with a password.
get hasProtectionPassword(): boolean
Returns boolean
isPerformingAsyncCalculations
Section titled "isPerformingAsyncCalculations"Indicates if the workbook is currently performing a calculation operation.
get isPerformingAsyncCalculations(): boolean
Returns boolean
isProtected
Section titled "isProtected"Returns a boolean indicating if the Workbook has been protected.
get isProtected(): boolean
Returns boolean
isSaving
Section titled "isSaving"Gets the value indicating whether the [[Workbook]] is currently being saved.
get isSaving(): boolean
Returns boolean
set isSaving(a: boolean): void Parameters
- a:
boolean
Returns void
iterativeCalculationsEnabled
Section titled "iterativeCalculationsEnabled"Gets or sets the value which indicates whether iterations are allowed while calculating formulas containing circular references.
get iterativeCalculationsEnabled(): boolean
Returns boolean
set iterativeCalculationsEnabled(a: boolean): void Parameters
- a:
boolean
Returns void
maxChangeInIteration
Section titled "maxChangeInIteration"Gets or sets the maximum change of the values in a formula between iterations which will exit from iteration.
get maxChangeInIteration(): number
Returns number
set maxChangeInIteration(a: number): void Parameters
- a:
number
Returns void
maxColumnCount
Section titled "maxColumnCount"Gets the maximum number of columns allowed in each worksheet based on the [[currentFormat]].
get maxColumnCount(): number
Returns number
maxRecursionIterations
Section titled "maxRecursionIterations"Gets or sets the maximum number of times formulas should be iteratively calculated.
get maxRecursionIterations(): number
Returns number
set maxRecursionIterations(a: number): void Parameters
- a:
number
Returns void
maxRowCount
Section titled "maxRowCount"Gets the maximum number of rows allowed in each worksheet based on the [[currentFormat]].
get maxRowCount(): number
Returns number
precision
Section titled "precision"Gets or sets the precision to use when obtaining a cell's value.
get precision(): Precision
Returns Precision
protection
Section titled "protection"Returns an object that provides information used when the Workbook has been protected.
get protection(): WorkbookProtection
Returns WorkbookProtection
recalculateBeforeSave
Section titled "recalculateBeforeSave"Gets or sets the value which indicates whether the workbook should recalculate all formulas before saving.
get recalculateBeforeSave(): boolean
Returns boolean
set recalculateBeforeSave(a: boolean): void Parameters
- a:
boolean
Returns void
saveExternalLinkedValues
Section titled "saveExternalLinkedValues"Gets or sets the value which indicates whether to save values linked from external workbooks.
get saveExternalLinkedValues(): boolean
Returns boolean
set saveExternalLinkedValues(a: boolean): void Parameters
- a:
boolean
Returns void
screenDpi
Section titled "screenDpi"Gets or sets the Dpi to use when calculating row and column sizes for the workbook. If empty, the system Dpi will be used.
get screenDpi(): IgSize
Returns IgSize
set screenDpi(a: IgSize): void Parameters
- a:
IgSize
Returns void
shouldRemoveCarriageReturnsOnSave
Section titled "shouldRemoveCarriageReturnsOnSave"Gets or sets the value which indicates whether carriage return characters should be removed from string values in cells when the workbook is saved to an Excel file.
get shouldRemoveCarriageReturnsOnSave(): boolean
Returns boolean
set shouldRemoveCarriageReturnsOnSave(a: boolean): void Parameters
- a:
boolean
Returns void
validateFormatStrings
Section titled "validateFormatStrings"Gets or sets the value indicating whether the format strings should be validated when they are set.
get validateFormatStrings(): boolean
Returns boolean
set validateFormatStrings(a: boolean): void Parameters
- a:
boolean
Returns void
windowOptions
Section titled "windowOptions"Gets the options which control various workbook level display properties.
get windowOptions(): WorkbookWindowOptions
Returns WorkbookWindowOptions
systemDpi
Section titled "systemDpi"Gets or sets the default Dpi to use when calculating row and column sizes for the workbook. If empty, the resolved system Dpi will be used.
get systemDpi(): IgSize
Returns IgSize
set systemDpi(a: IgSize): void Parameters
- a:
IgSize
Returns void
Methods
Section titled "Methods"_d9(): IEnumerable$1<KeyValuePair$2<string, number[]>> Returns IEnumerable$1<KeyValuePair$2<string, number[]>>
cancelAsyncCalculations
Section titled "cancelAsyncCalculations"Requests that any current calculation operation be cancelled.
cancelAsyncCalculations(): void Returns void
characterWidth256thsToPixels
Section titled "characterWidth256thsToPixels"Converts units of 1/256s of the average character width to pixels.
characterWidth256thsToPixels(characterWidth256ths: number): number Parameters
- characterWidth256ths:
numberThe number of units of 1/256s of the average character width.
Returns number
clearConnectionData
Section titled "clearConnectionData"Clears all external data connections from the [[Workbook]].
clearConnectionData(): void Returns void
clearPivotTableData
Section titled "clearPivotTableData"Clears all pivot tables and associated slicers from the [[Workbook]].
clearPivotTableData(): void Returns void
clearVbaData
Section titled "clearVbaData"Clears all vba information from the [[Workbook]].
clearVbaData(): void Returns void
createNewWorkbookFont
Section titled "createNewWorkbookFont"Factory method which creates new workbook font.
createNewWorkbookFont(): IWorkbookFont Returns IWorkbookFont
createNewWorksheetCellFormat
Section titled "createNewWorksheetCellFormat"Creates new worksheet cell format.
createNewWorksheetCellFormat(): IWorksheetCellFormat Returns IWorksheetCellFormat
customTableStyles
Section titled "customTableStyles"Gets the [[WorksheetTableStyle]] at the specified index.
customTableStyles(index: number): WorksheetTableStyle Parameters
- index:
numberThe index at which to get the WorksheetTableStyle.
Returns WorksheetTableStyle
customViews
Section titled "customViews"Gets the custom view at the specified index. The custom view at the specified index.
customViews(index: number): CustomView Parameters
- index:
numberThe zero-based index of the custom view to get.
Returns CustomView
getTable
Section titled "getTable"Gets the table with the specified name.
getTable(name: string): WorksheetTable Parameters
- name:
stringThe name of the table to get.
Returns WorksheetTable
isValidFunctionName
Section titled "isValidFunctionName"Gets a value indicating whether the specified function will be recognized and solved by Microsoft Excel when the workbook is saved out.
isValidFunctionName(functionName: string): boolean Parameters
- functionName:
stringThe case-insensitive name of the function.
Returns boolean
namedReferences
Section titled "namedReferences"Gets the named reference at the specified index. The named reference at the specified index.
namedReferences(index: number): NamedReference Parameters
- index:
numberThe zero-based index of the named reference to get.
Returns NamedReference
palette
Section titled "palette"Gets or sets a color in the palette.
palette(index: number, value: any): string Parameters
- index:
numberThe index of the color to get or set in the palette.
- value:
any
Returns string
pixelsToCharacterWidth256ths
Section titled "pixelsToCharacterWidth256ths"Converts pixels to units of 1/256s of the average character width.
pixelsToCharacterWidth256ths(pixels: number): number Parameters
- pixels:
numberThe number of pixels.
Returns number
protect
Section titled "protect"Protects the Workbook without a password.
protect(allowEditStructure: boolean, allowEditWindows: boolean): void Parameters
- allowEditStructure:
booleanOptional boolean indicating the new value for the [[WorkbookProtection.allowEditStructure]].
- allowEditWindows:
booleanOptional boolean indicating the new value for the [[WorkbookProtection.allowEditWindows]].
Returns void
recalculate
Section titled "recalculate"Recalculates all dirty formulas pending a calculation on the workbook.
recalculate(): void Returns void
recalculateAsync
Section titled "recalculateAsync"Recalculates all formulas on the workbook.
recalculateAsync(includeNonDirtyFormulas: boolean): void Parameters
- includeNonDirtyFormulas:
booleanTrue to recalculate all formulas on the workbook regardless of whether they had a pending evaluation. False to only calculate dirty formulas.
Returns void
registerUserDefinedFunction
Section titled "registerUserDefinedFunction"Registers a single [[ExcelCalcFunction]] instance.
registerUserDefinedFunction(userDefinedFunction: ExcelCalcFunction): boolean Parameters
- userDefinedFunction:
ExcelCalcFunctionUser defined function instance to register
Returns boolean
resumeCalculations
Section titled "resumeCalculations"Resumes the calculation of formulas.
resumeCalculations(): void Returns void
Writes the workbook to a Uint8Array.
save(saveOptions: WorkbookSaveOptions, successCallback: object, failCallback: object): void Parameters
- saveOptions:
WorkbookSaveOptionsThe options to use to save the stream or null to use the default options.
- successCallback:
objectThe function to call when the Workbook has been successfully saved into a Uint8Array or base-64 encoded string.
- failCallback:
objectThe function to call when saving the Workbook has caused an error.
Returns void
setCurrentFormat
Section titled "setCurrentFormat"Sets the current format of the workbook.
setCurrentFormat(format: WorkbookFormat): void Parameters
- format:
WorkbookFormatThe file format to use when imposing format restrictions and saving.
Returns void
sheets
Section titled "sheets"Gets the sheet at the specified index. The sheet at the specified index.
sheets(index: number): Sheet Parameters
- index:
numberThe zero-based index of the sheet to get.
Returns Sheet
standardTableStyles
Section titled "standardTableStyles"Gets the [[WorksheetTableStyle]] at the specified index.
standardTableStyles(index: number): WorksheetTableStyle Parameters
- index:
numberThe index at which to get the WorksheetTableStyle.
Returns WorksheetTableStyle
styles
Section titled "styles"Gets the style at the specified index. The style at the specified index.
styles(index: number): WorkbookStyle Parameters
- index:
numberThe zero-based index of the style to get.
Returns WorkbookStyle
suspendCalculations
Section titled "suspendCalculations"Temporarily suspends the calculation of formulas.
suspendCalculations(): void Returns void
unprotect
Section titled "unprotect"Removes the Workbook protection.
unprotect(): void Returns void
worksheets
Section titled "worksheets"Gets the worksheet at the specified index. The worksheet at the specified index.
worksheets(index: number): Worksheet Parameters
- index:
numberThe zero-based index of the worksheet to get.
Returns Worksheet
getMaxColumnCount
Section titled "getMaxColumnCount"Returns the number of columns that are supported by the specified format.
getMaxColumnCount(format: WorkbookFormat): number Parameters
- format:
WorkbookFormatThe format used by the workbook.
Returns number
getMaxRowCount
Section titled "getMaxRowCount"Returns the number of rows that are supported by the specified format.
getMaxRowCount(format: WorkbookFormat): number Parameters
- format:
WorkbookFormatThe format used by the workbook.
Returns number
getWorkbookFormat
Section titled "getWorkbookFormat"Returns the WorkbookFormat based on the file extension of the specified file.
getWorkbookFormat(fileName: string): WorkbookFormat | null Parameters
- fileName:
stringThe filename of an excel file.
Returns WorkbookFormat | null
isWorkbookEncrypted
Section titled "isWorkbookEncrypted"Determines whether the workbook in the specified stream is encrypted with an open password.
isWorkbookEncrypted(stream: string | Uint8Array<ArrayBufferLike>): boolean Parameters
- stream:
string | Uint8Array<ArrayBufferLike>The stream to check for encryption.
Returns boolean
Loads a workbook from a File.
load(file: File, loadOptions: WorkbookLoadOptions, successCallback: object, failCallback: object): void Parameters
- file:
FileThe file from which to load the workbook.
- loadOptions:
WorkbookLoadOptionsThe options to use to load the stream or null to use the default options.
- successCallback:
objectThe function to call when the Workbook has been successfully loaded.
- failCallback:
objectThe function to call when loading the Workbook has resulted in an error.
Returns void
staticInit
Section titled "staticInit"staticInit(): void