Skip to content

XLSX: cache #SPILL! and #CALC! as #VALUE! so Excel can open the file - #85

Merged
h-a-n-a-s-h-i merged 2 commits into
storytold:mainfrom
nihilist-narwhal:xlsx-spill-cached-errors
Oct 10, 2026
Merged

h-a-n-a-s-h-i merged 2 commits into
storytold:mainfrom
nihilist-narwhal:xlsx-spill-cached-errors

Conversation

@nihilist-narwhal

@nihilist-narwhal nihilist-narwhal commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

A formula whose value is #SPILL! (a blocked spill) or #CALC! is written with that error as its cached value. Neither is an error code of the XLSX file format, and Excel refuses to open such a file: on Excel for Mac 16.113, opening it fails with "Parameter error (-50)". So any workbook containing a blocked spill could not be opened in Excel.

Excel itself caches these errors as #VALUE! when it saves, so the writer now does the same. #SPILL!/#CALC! inside a cached array value are mapped too. Other errors (#N/A, #DIV/0!…) are unchanged, and GridCraft still shows the real error in its own UI, since it recalculates on open.

The second commit adds my entry to contributors/people.toml.

They are not error codes of the file format, and Excel refuses to open a
file whose cached values contain them ("Parameter error"). Any workbook
with a blocked spill could not be opened in Excel. Excel caches these
errors as #VALUE! itself.
@echelon

echelon commented Oct 10, 2026

Copy link
Copy Markdown
Member

Merged into main — thank you for the contribution! It was reviewed, merged together with a batch of other community PRs, and checked against the full build and lint gate.

If you haven't already, please come join us on Discord: https://discord.gg/artcraft — we'd love to have you around.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants