Skip to content
Sheetwrite

@sheetwrite/core

XlsxFormulaEngineinterface

Report a problem

On this page

The engine's formula text operations that one XLSX read or write uses.

Members

Methods

convert(formulas: string[], direction: "import" | "export"): string[];

Convert formulas between editor and OOXML spelling, in input order.

arrayFormulas(formulas: string[]): Uint32Array;

The indices of the editor-spelling formulas whose result is an array, ascending. Each is read without a workbook, so a name never counts.

lexes(formula: string): boolean;

Whether the engine's lexer reads all of formula; copy changes nothing in text it cannot read.

copy(formula: string, rowDelta: number, colDelta: number): string;

The formula as a copy rowDelta rows down and colDelta columns right holds it: the copy rule that paste and fill use. Relative references move, absolute parts stay, whole columns keep their rows, whole rows keep their columns, and a reference that leaves the sheet becomes #REF!.

Declaration

View full TypeScript declaration
export interface XlsxFormulaEngine {
convert(formulas: string[], direction: "import" | "export"): string[];
arrayFormulas(formulas: string[]): Uint32Array;
lexes(formula: string): boolean;
copy(formula: string, rowDelta: number, colDelta: number): string;
}

Referenced by

Public exports naming XlsxFormulaEngine