Skip to content
SumOfficeSumOfficeSumOffice

Types: cells and ranges

Compute Contract type definitions — addressing, content, clipboard, search, sorting, and edit history. Names: 22.

Definitions of the names from the “TypeScript type” column on the operation pages.

Other dictionary topics: session, workbook, and sheets · cells and ranges · formulas and calculation · formatting · data and sheet objects · pivot tables · charts and graphics · printing and page layout · Power Query · VBA and macros · protection and review · general and utility.

interface CellAnchor {
row: number;
col: number;
}
type CellInputEdit =
| { inputKind: "sheet-protection"; sheetKey: string; row: number; col: number; protected: boolean; }
| { inputKind: "fill-series";
sheetKey: string;
row: number;
col: number;
rowEnd: number;
colEnd: number;
axis: "rows"
| "columns"; seriesType:
| "linear"
| "growth"
| "date"
| "autofill"
| "fill-down"
| "fill-up"
| "fill-left"
| "fill-right"; dateUnit: "day"
| "weekday"
| "month"
| "year"; stepValue: string; stopValue?: string
| null; }
| { inputKind: "drag-fill";
sheetKey: string;
row: number;
col: number;
rowEnd: number;
colEnd: number;
sourceRow: number;
sourceCol: number;
sourceRowEnd: number;
sourceColEnd: number;
axis: "rows"
| "columns"; }
| { inputKind: "prepared-cell";
sheetKey: string;
row: number;
col: number;
raw: string;
display: string;
formula?: string
| null; cellType?: string
| null; styleIndex?: number
| null; richTextRuns?: ContractRichTextRun[]; }
| { inputKind: "raw-user-input";
sheetKey: string;
row: number;
col: number;
input: string;
locale?: string;
}
| { inputKind: "number"; sheetKey: string; row: number; col: number; input: string; }
| { inputKind: "text"; sheetKey: string; row: number; col: number; input: string; }
| { inputKind: "empty-string"; sheetKey: string; row: number; col: number; }
| { inputKind: "clear-to-blank"; sheetKey: string; row: number; col: number; }
| { inputKind: "clear-formatting"; sheetKey: string; row: number; col: number; }
| { inputKind: "formula"; sheetKey: string; row: number; col: number; input: string; }
| { inputKind: "legacy-array-formula";
sheetKey: string;
row: number;
col: number;
input: string;
refRange: string;
}
| { inputKind: "formatting";
sheetKey: string;
row: number;
col: number;
fillColor?: string;
fontColor?: string;
numberFormat?: string;
fontFamily?: string;
fontSize?: number;
bold?: boolean;
italic?: boolean;
fontVerticalAlign?: ContractPreviewFontVerticalAlign;
underlineKind?: ContractPreviewUnderlineKind;
underline?: boolean;
strike?: boolean;
horizontalAlign?: string
| null; verticalAlign?: string
| null; wrapText?: boolean; shrinkToFit?: boolean; locked?: boolean; hidden?: boolean; diagonalUp?: boolean; diagonalDown?: boolean; borderPreset?:
| "all"
| "none"
| "bottom"
| "top"
| "left"
| "right"
| "outside-thin-all"
| "outside-thin-top"
| "outside-thin-bottom"
| "outside-thin-left"
| "outside-thin-right"
| "outside-thin-top-bottom"
| "outside-thin-top-left"
| "outside-thin-top-right"
| "outside-thin-bottom-left"
| "outside-thin-bottom-right"
| "outside-thin-left-right"
| "outside-thin-top-bottom-left"
| "outside-thin-top-bottom-right"
| "outside-thin-top-left-right"
| "outside-thin-bottom-left-right"
| "outside-thick-all"
| "outside-thick-top"
| "outside-thick-bottom"
| "outside-thick-left"
| "outside-thick-right"
| "outside-thick-top-bottom"
| "outside-thick-top-left"
| "outside-thick-top-right"
| "outside-thick-bottom-left"
| "outside-thick-bottom-right"
| "outside-thick-left-right"
| "outside-thick-top-bottom-left"
| "outside-thick-top-bottom-right"
| "outside-thick-top-left-right"
| "outside-thick-bottom-left-right"
| "outside-double-all"
| "outside-double-top"
| "outside-double-bottom"
| "outside-double-left"
| "outside-double-right"
| "outside-double-top-bottom"
| "outside-double-top-left"
| "outside-double-top-right"
| "outside-double-bottom-left"
| "outside-double-bottom-right"
| "outside-double-left-right"
| "outside-double-top-bottom-left"
| "outside-double-top-bottom-right"
| "outside-double-top-left-right"
| "outside-double-bottom-left-right"
| "green-all"
| `border-line-${string}`
| `border-color-${string}`; textRotation?: number; indent?: number; };
interface CellRange {
sheetKey: string;
rowStart: number;
rowEnd: number;
colStart: number;
colEnd: number;
}
interface CellRect {
top: number;
left: number;
rows: number;
cols: number;
}
interface ContractCellDetails {
cellKey: string;
address: string;
displayValue: string | null;
editText: string | null;
calculationTrust?: ContractCalculationTrust | null;
}
interface ContractEntityCellMetadata {
cellKey: string;
stableEntityId: string;
kind: ContractEntityDataTypeKind;
state: ContractEntityResolutionState;
provider: ContractEntityProviderIdentity;
originalText: string;
displayText: string;
fields: ContractEntityFieldValue[];
}
interface ContractFindIndexStats {
cacheHit: boolean;
indexedCellCount: number;
indexedBytes: number;
queryCacheBytes: number;
indexBuildCount: number;
workbookRevision: number;
invalidationCount: number;
lastInvalidatedCellCount: number;
lastInvalidatedRangeCount: number;
lastInvalidatedSheetCount: number;
lastReconciledQueryCount: number;
fullResetCount: number;
}
type ContractFindLookIn = "values" | "formulas";
interface ContractFindMatch {
cellKey: string;
sheetName: string;
address: string;
value: string;
}
type ContractFindScope = "active_sheet" | "workbook" | { selection: { range: CellRange } };
type ContractFindSearchOrder = "by_rows" | "by_columns";
interface ContractFormControlLinkedCellWrite {
sheetKey: string;
row: number;
col: number;
display: string;
}
interface ContractObjectAnchorCell {
row: number;
col: number;
dxEmu: number;
dyEmu: number;
}
interface ContractOpenDocumentReplacementRange {
rowStart: number;
rowEnd: number;
colStart: number;
colEnd: number;
}
interface ContractParameterNumericRange {
min: number;
max: number;
}
interface ContractPreviewCell {
row: number;
col: number;
value: string;
valueKind: ContractPreviewValueKind;
scalarValueKind?: "number" | "text" | "date";
delimitedValueKind?: "number" | "text" | "date" | "emptyString";
delimitedSemanticValue?: string;
rawFormula?: string;
selectionAllowed?: boolean;
hyperlink?: ContractPreviewHyperlink | null;
booleanValue?: boolean | null;
errorCode?: ContractErrorCode | null;
formatting?: ContractPreviewFormatting | null;
richTextRuns?: ContractRichTextRun[] | null;
}
interface ContractWhatIfCellRef {
sheetKey: string;
row: number;
col: number;
}
interface ContractXlsxCellCopyPatch {
activeSheetPath: string;
sourceCellRef: string;
targetCellRef: string;
}
type ContractXlsxCellShiftDirection = | "insert-shift-right" | "insert-shift-down" | "delete-shift-left" | "delete-shift-up";
interface ContractXlsxCellShiftPatch {
activeSheetPath: string;
rowStart: number;
rowEnd: number;
colStart: number;
colEnd: number;
direction: ContractXlsxCellShiftDirection;
}
interface DeltaSummary {
deltaId: string;
changedCellCount: number;
}
type SourceCellDescriptor =
| { kind: "blank" }
| { kind: "text"; value: string }
| { kind: "number"; value: number }
| { kind: "integer"; value: number }
| { kind: "logical"; value: boolean }
| { kind: "date"; year: number; month: number; day: number }
| { kind: "error"; code: string };

Documentation assistant

Answers are assembled from the documentation and may be inaccurate — check the sources.