lxHandle, lxDataToXLS, and lxGridToXLS
TXLSWorksheet.CopyGroup methods copy an existing represented group subtree into an outer worksheet area or into an existing destination parent group, with current typed state and explicit resource and failure boundaries
The methods belong to the concrete TXLSWorksheet class, whilst the existing worksheet members stay unchanged
TXLSWorkbook.BeginBatch opens a batch and EndBatch closes it, answering the number of changed cells it folded together; InBatch reports whether one is open, BatchCellCount how many cells it has seen, and the internal TXLSBatchRect record holds one sheet's changed rectangle
Whilst a batch is open, cell changes collect as one bounding rectangle per sheet instead of marking the dependency graph for every cell; EndBatch marks every rectangle just once. A formula structure change inside the batch keeps its usual meaning and invalidates the graph a single time, while writes outside a batch behave exactly as they did
The saving is the per-cell graph lookup: twenty thousand writes into a workbook whose graph holds two thousand ranges take 157 ms unbatched and 15 ms inside one batch on the reference machine, whilst the recalculated values are identical. Batches nest, an empty batch answers zero, and a batch never evaluates anything by itself — call Recalculate afterwards
property CalculationMode: LongWord;
property FormulaArrayMemoryLimit: Int64;
property EnableIteration: Boolean;
property MaxIterations: LongWord;
property MaxIterationChange: Double;
property RecalcOnSave: Boolean;
property UseFullPrecision: Boolean;
| CalculationMode | Controls the workbook calculation mode stored with the file |
| FormulaArrayMemoryLimit | Bounds the payload allocated by generated formula arrays such as MUNIT, defaults to 64 MiB, and clamps values below a single Double element |
| EnableIteration | Enables iterative calculation for circular formulas |
| MaxIterations | Upper limit on Gauss-Seidel passes for each circular-reference strongly connected component |
| MaxIterationChange | Largest numeric delta tolerated before a circular-reference component halts its iteration |
| RecalcOnSave | Requests workbook recalculation when Excel saves the file |
| UseFullPrecision | Keeps full formula precision; when it is off, formula and What-If data-table caches get rounded to their effective displayed numeric precision before dependants read them |
property IXLSWorkbook.FormulaEntryPolicy: TXLSFormulaEntryPolicy;
function TXLSWorksheet.ValidateFormulaEntry(Row, Col: Integer;
const Formula: WideString): TXLSFormulaEntryValidationResult;
property RenderCalibration: TXLSRenderCalibration;
function CaptureRenderCalibration: TXLSRenderCalibration;
procedure ResetRenderCalibration;
function CreateRenderGeometry(ABackend: TXLSRenderGeometryBackend;
ACacheCapacity: Integer = 4096): IXLSRenderGeometry;
CaptureRenderCalibration returns an independent value snapshot for a single measurement or export operation, and ResetRenderCalibration restores the standard 1/1/1/1/100/96 values
CreateRenderGeometry copies the current calibration into an operation-owned service and binds its cache identity to the current workbook generation and chosen backend; later workbook calibration changes cannot alter an existing service
TXLSPaginationModel.Build call capture the workbook calibration once; AutoFit is the only consumer that deliberately writes fitted dimensions, whilst pagination preserves every stored row height and column width
property Title: WideString;
property Subject: WideString;
property Author: WideString;
property Keywords: WideString;
property Comments: WideString;
property Company: WideString;
property Manager: WideString;
function Close: Integer;
Classic GetSheetNames(FileName, AList) reads through the same record-wise reader as its existing Stream overload; missing-file failure, ZIP dispatch, stream ownership and borrowed-stream cursor behaviour keep their contracts
Low-level serialiser callers can keep the legacy declarations or pick explicit 64-bit aggregate and position helpers
| Owner | 64-bit entry | Contract |
|---|---|---|
| TXLSBlobList | TotalSize64: Int64 | Checked aggregate length; legacy TotalSize: LongWord refuses overflow |
| TXLSDBCell | Create64, StartRowBlock64, AddRowBookmark64, FinalRowBlock64, DBCellOffset64 | Internal Int64 positions, with actual relative wire fields checked on emission |
| TXLSDBCellIndex | RegisterRowBlock64, GetData64 | Checked cumulative INDEX pointer serialisation |
| TXLSStringTable | AddSSTData64 | Int64 offset plus the existing font-run remap array, with actual ExtSST pointers verified |
| TCondFormatter and TDataValidator | Store64(DList: TXLSBlobList): Int64 | Aggregate record lengths without the legacy Integer result width |
| lxBlob helpers | XLSBiffCheckedAdd(Left, Right: Int64): Int64, XLSBiffUInt32(Value: Int64): LongWord | Reject negative aggregate terms, Int64 overflow and unsigned32 wire values that cannot be represented |
Legacy 32-bit counterparts remain available for callers that never go beyond LongWord offsets: TXLSDBCell.StartRowBlock, AddRowBookmark and FinalRowBlock take LongWord positions, the read-only DBCellOffset property gives back the same position as LongWord and rejects a stored Int64 wider than that, BookmarkFirstRow and BookmarkLastRow report the first and last row captured in the current row block, and TXLSDBCellIndex.RegisterRowBlock records a cumulative INDEX pointer with the same LongWord width
Separately named entries preserve the existing value-parameter declarations without bringing in ambiguous Integer/LongWord/Int64 overloads
Legacy Store can serialise records before it discovers that its aggregate return requires Store64; it promises no rollback of a caller-owned list, so use Store64 for new aggregate code
Workbook saving uses its existing staged publication boundary; low-level helpers keep their own partial-list/error behaviour, and changed class layouts require binary consumers to be rebuilt
See wire widths and qualification and bounded sheet-name discovery for measured behaviour and remaining scope
property MetadataOnly: Boolean;
property SelectedSheets: TStringList;
property IncompleteLoad: Boolean;
| MetadataOnly | When set before Open, reads only workbook metadata and sheet descriptors and skips cell data |
| SelectedSheets | Sheet names to load when the workbook is opened; an empty list pulls in every sheet |
| IncompleteLoad | True after Open when cell data was skipped because MetadataOnly or SelectedSheets was used |
MetadataOnly or a non-empty
SelectedSheets cannot be saved; Save raises
an error until the workbook is reopened without those options
property TXLSWorksheet._ColumnInfo: TXLSColumnInfoList;
property TXLSColumnInfo.Collapsed: Boolean;
property TXLSRowInfo.Collapsed: Boolean;
property TXLSColumnInfoList.Collapsed[Index: Integer]: Boolean;
Collapsed exposes the BIFF column outline marker independently of Hidden and OutlineLevel. The list index is a zero-based classic XLS column index. Missing columns come back as False, and assigning False to a missing column allocates no metadata. Column-format copies, worksheet copies, and save-and-reopen cycles preserve the marker
TXLSRowInfo reports MinCol and MaxCol (the covered one-based column span), CustomHeight and CustomFormat (whether an explicit height or XF index is stored), and XFIndexSet; TXLSColumnInfo.isEqual compares two column metadata entries field by field
TXLSColumnInfoList exposes ColCount, MinCol, MaxCol, StdWidth, and MaxOutlineLevel for bounds and default-width diagnostics, CalcMaxOutLineLevel recomputes the cached maximum outline level after direct metadata edits, CopyColFormat clones one column entry onto another index, DeleteCol removes an entry, and FindNextColToStore walks stored entries for BIFF COLINFO record writers, reporting the next span in the MinCol / MaxCol out-parameters
function TryGetOutlineNode(AAxis: TXLSOutlineAxis; ANodeIndex: Integer; out ANode: TXLSOutlineNode): Boolean;
function SetOutlineNodeCollapsed(AAxis: TXLSOutlineAxis; ANodeIndex: Integer; ACollapsed: Boolean; AChildMode: TXLSOutlineChildMode = xocPreserve): Boolean;
procedure SetOutlineDisplayLevel(AAxis: TXLSOutlineAxis; ADisplayLevel: Integer; AChildMode: TXLSOutlineChildMode = xocPreserve);
ANodeIndex is the one-based physical summary row or column, ADisplayLevel follows the one-based outline-button convention, and xocPreserve keeps nested child collapse markers independent by default
function ThawPanes(Y, X: Single; RowTop, ColLeft: Word): Integer;
function SplitPanes(Width, Height: Single): Integer;
function UnsplitPanes: Integer;
function GetSelectedAreas(APane: TXLSPanePosition; out ActiveAreaIndex: Integer): TXLSSelectedAreas;
function SelectAreas(APane: TXLSPanePosition; const Areas: array of WideString; ActiveAreaIndex: Integer = 0): Boolean;
function TryGetWindowScroll(APane: TXLSPanePosition; out ARow, ACol: Integer): Boolean;
function ScrollWindow(APane: TXLSPanePosition; ARow, ACol: Integer): Boolean;
function RepeatRows(FirstRow, LastRow: Word): Integer;
function RepeatColumns(FirstCol, LastCol: Word): Integer;
ThawPanes, SplitPanes, and UnsplitPanes control split-pane state, while RepeatRows and RepeatColumns set print-title rows or columns for the worksheet
GetSelectedAreas and the pane-first SelectAreas overload provide the shared logical-pane selection contract described in Worksheet pane selections
xlsDiagnosticSelectionRecordInvalid rather than exposing partially trusted typed state
TryGetWindowScroll and ScrollWindow expose the shared 1-based four-pane scroll contract, mapping the upper and left axes onto Window2 and lower and right axes to Pane
function AddWholeNumberValidation(ARange: WideString; AOp: TXLSDvOperator; const AFormula1: WideString; const AFormula2: WideString = ''): TDataValidation;
function AddDecimalValidation(ARange: WideString; AOp: TXLSDvOperator; const AFormula1: WideString; const AFormula2: WideString = ''): TDataValidation;
function AddDateValidation(ARange: WideString; AOp: TXLSDvOperator; const AFormula1: WideString; const AFormula2: WideString = ''): TDataValidation;
function AddTimeValidation(ARange: WideString; AOp: TXLSDvOperator; const AFormula1: WideString; const AFormula2: WideString = ''): TDataValidation;
function AddTextLengthValidation(ARange: WideString; AOp: TXLSDvOperator; const AFormula1: WideString; const AFormula2: WideString = ''): TDataValidation;
function AddCustomValidation(ARange: WideString; const AFormula: WideString): TDataValidation;
ARange and returns the created TDataValidation instance so prompt, error, and blank-handling options can be adjusted
property PivotTables: TXLSPivotTables;
function AddPivotTable(const SourceRangeA1: WideString; DestRow, DestCol: Integer; const Name: WideString): TXLSPivotTable;
function PivotSetDataFieldFormat(DataField: TXLSPivotDataField; const FormatStr: WideString): Word;
AddPivotTable to create a typed pivot table from a source range, then use PivotTables and PivotSetDataFieldFormat to inspect or format the generated model. See Classic XLS pivot table API
function SetArrayFormula(const Formula: WideString): Integer;
function XFIndex: Integer;
property FirstRow: Word;
property LastRow: Word;
property FirstCol: Byte;
property LastCol: Byte;
SetArrayFormula assigns an array formula to the range. FirstRow, LastRow, FirstCol, and LastCol expose the stored 1-based range bounds, while XFIndex returns the effective classic XLS format index for the range
procedure PasteFrom(SrcRange: TXLSRange; PasteMode: LongWord; CopyMode: Boolean);
procedure ShiftTo(Row: Word; Col: Byte);
procedure ExtendRange;
procedure ContractRange;
PasteFrom applies cell content from another classic XLS range through the selected paste mode. ShiftTo repositions a range object, while ExtendRange and ContractRange adjust the stored rectangle before range operations that need expanded or normalised bounds
interface IXLSRowsRange = interface(IXLSRange)
property Item[Row: Integer]: IXLSRowRange;
property Hidden: OleVariant;
property Count: LongWord;
procedure AutoFit(Columns: Boolean = False);
interface IXLSRowRange = interface(IXLSRange)
property Item[Col: Integer]: IXLSColRange;
property Hidden: OleVariant;
property Count: LongWord;
procedure AutoFit(Columns: Boolean = False);
interface IXLSColsRange = interface(IXLSRange)
property Item[Col: Integer]: IXLSColRange;
property Hidden: OleVariant;
property Count: LongWord;
procedure AutoFit(Columns: Boolean = True);
procedure Group(Rows: Boolean = False);
procedure UnGroup(Rows: Boolean = False);
property OutlineLevel: Integer;
interface IXLSColRange = interface(IXLSRange)
property Item[Row: Integer]: IXLSRowRange;
property Hidden: OleVariant;
property Count: LongWord;
procedure AutoFit(Columns: Boolean = True);
procedure Group(Rows: Boolean = False);
procedure UnGroup(Rows: Boolean = False);
property OutlineLevel: Integer;
IXLSRowsRange, IXLSRowRange, IXLSColsRange, and IXLSColRange are returned by IXLSRange.Rows, IXLSRange.Columns, IXLSRange.EntireRow, and IXLSRange.EntireColumn. They keep the normal IXLSRange editing surface while adding indexed row or column access, hidden-state control, counts, autofit and outline grouping wherever the range direction supports it
property DisplayText: WideString;
DisplayText reads or changes the visible text Excel shows for a classic XLS hyperlink, kept apart from the target address and screen tip
property IndexByID[SheetID: Integer]: Integer;
property IDByName[SheetName: WideString]: Integer;
property NameByID[SheetID: Integer]: WideString;
property SheetTypeRaw: Byte;
SheetTypeRaw preserves the raw classic XLS BoundSheet8.dt value while loading and saving workbooks, so macro, VBA, worksheet, dialog and other sheet-type records can round-trip without being flattened into a standard worksheet tab
Version 2.384.519 keeps represented local print areas together with repeating row and column titles when a Classic worksheet is copied inside its workbook or into a different workbook, then saved and reopened
The copied ranges belong to the destination worksheet, even for a renamed copy at another sheet index; if the source workbook is released before a file or stream save, no reference to the original sheet is left behind
Print ranges of one or several areas, row titles, column titles and their combinations keep distinct local name identities; a copy of unset print metadata adds no print name
The repair preserves the existing binary name validation and opaque printer data; it does not amount to unrestricted drawing copies, native printing, printer-driver execution or qualification for further platforms
property PrintNotesAtEnd: Boolean;
property UseFirstPageNumber: Boolean;
property FirstPageNumber: Integer;
property PrintCellErrors: LongWord;
property PrintResolution: LongWord;
property PrintVResolution: LongWord;
property Copies: LongWord;
property HasSetupRecord: Boolean; read only
property PrinterSettingsInitialized: Boolean; read only
property PrinterDriverData: TBytes;
property HasPrinterDriverData: Boolean; read only
procedure ClearPrinterDriverData;
HasSetupRecord reports whether a loaded classic XLS worksheet contains a BIFF Setup record, whilst PrinterSettingsInitialized reports whether its paper size, scale, orientation, resolution and copy count are defined by that record
Setup record and an existing record byte for byte; changing a page-setup field creates the record when needed, and changing a printer-dependent field initialises the printer settings
PrinterDriverData reads or replaces the opaque BIFF PLS printer-driver payload, HasPrinterDriverData distinguishes an absent payload, and ClearPrinterDriverData removes it without changing typed page-setup fields
SaveXLSWorkbookAsXLSX carries typed page-setup values independently and removes the Classic prefix only from a recognised Windows printer body; unmatched bodies retain same-format preservation and explicitly refuse cross-format conversion, while typed standard fields stay authoritative when private bytes contain duplicate defaults; see printer-setting format boundaries
property CharSet: Byte;
property Family: Byte;
CharSet and Family expose the classic XLS font character-set and family bytes for callers that need to keep locale-specific font metadata
procedure TDataToXLS.Abort;
procedure TGridToXLS.Abort;
Abort from export event handlers when a running dataset or grid export has to stop before it finishes
function GetCellRef(Cell: String; var Row, Col: Word): Integer;
function GetCellRange(CellRange: String; var StartRow, StartCol, EndRow, EndCol: Word): Integer;
function EncodeCellRef(Row, Col: Word): String;
function EncodeCellRange(StartRow, StartCol, EndRow, EndCol: Word): String;
function Width2Excel(Value: Single): Word;
function Excel2Width(Value: Word): Single;
function Height2Excel(Value: Single): Word;
function Excel2Height(Value: Word): Single;
function ColIndexToColName(Index: Integer): String;
function ColNameToColIndex(Name: String): Integer;
See the qualified expanded lifecycle and its remaining boundaries for the newer finite contract