HotXLS Docs

Classic external-sheet reference continuations

Keep complete XTI references through save and reopen

The Classic BIFF8 ExternSheet record holds the existing typed worksheet-reference intervals as six-byte XTI entries, preceded by an unsigned sixteen-bit entry count

The writer takes a fixed physical-record buffer and preserves the existing ExternSheet and ordinary Continue byte layout, including an entry split across a physical boundary

The reader consumes every admitted segment instead of parsing only the first physical body, so a correctly written multi-record reference table can normally reopen with all its typed identities and 3D formulas

Count admission and physical framing

BoundaryQualified behaviour
At most 65535 entriesCheck the complete Integer count before narrowing it to the BIFF unsigned sixteen-bit field
65536 or 65537 entriesRefuse explicitly ahead of public output publication instead of wrapping the count to zero or one
BIFF8 physical outputUse at most 8224 payload bytes plus a four-byte record header
Logical input sizeRequire exactly two count bytes plus six bytes for each declared entry, at most 393212 bytes
Tuple split across segmentsRead successive little-endian words without adding a string continuation flag

Checked Int64 planning takes in every physical header and validates both Workbook and destination totals; all output owners resolve before the first reference record is appended

Input framing is checked across the complete segment collection before adding the declared typed entries; this adds no whole-workbook rollback after an unrelated failed Open

The legacy BIFF5 input uses its existing separate parser, whilst other record families retain their own continuation rules

Representative count and formula controls

Actual controls cover 1370 entries within the first physical record, 1371 entries spanning it, 10923 entries crossing the old aggregate length width, and the maximum 65535 entries spread over 48 physical records

The maximum fixture uses 362 worksheets and unique worksheet intervals instead of inventing 65535 worksheets

Normal reopen, complete typed counts, real 3D formula results, source destruction, formula edits and a further save/reopen establish the positive path

Derived missing, extra, wrong-count, wrong-extent and short maximum-count segments supply parser refusal controls, alongside explicit oversized-count sentinel retention and valid retry

Fixed output buffer and resident reference model

The reference writer allocates a single buffer of at most 8228 bytes, without materialising another complete logical XTI field

The reader walks the retained segments directly instead of constructing a temporary complete combined field; raw segments and the typed reference model remain resident

Reference-list rebuilding, owner keys, worksheet staging and other Workbook allocations still lead the representative maximum-count whole-save measurement; fixed-buffer output is not a whole-save peak-reduction guarantee

Fixed-buffer output therefore does not imply a fixed whole-process memory ceiling, larger BIFF field widths or a fresh greater-than-2-GiB acceptance claim

Native evidence and source identity

Independent inspection reads every tuple and the actual formula reference indices, and compares physical output with the preserved old writer's valid byte layout

Genuine small external-reference controls tie selected native formula and cache observations to their exact source generations; they do not claim a new native run for the 65535-entry fixture

Complete-stream identity and qualified record identity are logged separately when the separately released Theme persistence changes unrelated Workbook globals

Remaining reference and wide-storage work

The adjacent supporting-link owner output separately governs external names and XCT/CRN cache children

Unknown owner semantics, other narrow metadata fields, broader source/model copying and the remaining drawing or compatibility work keep their stated boundaries in compound-file storage