RecursiveAI.OneDocument.Spreadsheets 1.0.0

dotnet add package RecursiveAI.OneDocument.Spreadsheets --version 1.0.0
                    
NuGet\Install-Package RecursiveAI.OneDocument.Spreadsheets -Version 1.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="RecursiveAI.OneDocument.Spreadsheets" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="RecursiveAI.OneDocument.Spreadsheets" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="RecursiveAI.OneDocument.Spreadsheets" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add RecursiveAI.OneDocument.Spreadsheets --version 1.0.0
                    
#r "nuget: RecursiveAI.OneDocument.Spreadsheets, 1.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package RecursiveAI.OneDocument.Spreadsheets@1.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=RecursiveAI.OneDocument.Spreadsheets&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=RecursiveAI.OneDocument.Spreadsheets&version=1.0.0
                    
Install as a Cake Tool

RecursiveAI.OneDocument.Spreadsheets

Read, write, calculate, template and render Word, Excel and PowerPoint documents (OOXML, legacy binary, RTF, ODF) in pure .NET. Not affiliated with Microsoft.

This package is the spreadsheet part of OneDocument (a preview, not yet published). It opens, edits and saves XLSX, XLSM, XLTX, XLSB and Flat OPC workbooks, reads legacy XLS and writes BIFF8 XLS, reads and writes CSV and TSV, streams rows and cells of very large sheets, and calculates: cached values are what you read, opening never recalculates, and Workbook.Recalculate() runs the formulas when you ask.

  • Lossless. Parts you did not edit are written back byte-identical. Editing one cell rewrites only its sheet part; unknown row and cell attributes, extLst and mc:AlternateContent survive.
  • Compact. Cells live in a columnar, sparse store: about 37 bytes per cell on a workbook with styles, strings and formulas, and about 0 bytes allocated per cell while iterating.
  • Streaming. XlsxStreamReader and XlsxStreamWriter work forward-only at constant memory with no allocation per cell. XlsbStreamReader and XlsStreamReader read binary workbooks (.xlsb, .xls) the same way, and Spreadsheet.Read<T> and Office.ExtractText use them.
  • Typed rows. Mark a partial class, struct or record with [SpreadsheetRow] and Spreadsheet.Read<T>(path) / Spreadsheet.Write(path, rows) move it to and from XLSX, CSV and TSV in one call, streaming. A source generator that ships in this package writes the binding when you compile, so there is no reflection and it works under trimming and NativeAOT.
  • Safe. The format is found from the content, never the extension. Damage is reported as typed defects with cell addresses or part offsets, and resource limits are on by default.
  • No setup. Office.Open reaches workbooks as soon as this package is referenced; no registration call is needed.
  • Legacy workbooks. Workbook.Open("old.xls") reads Excel 2.0 to 2003 files (BIFF2 to BIFF8) into the same model, with a loss report (Workbook.ImportLoss); Office.Convert("old.xls", "new.xlsx") is one line. See docs/xls.md.
  • Excel's number formats (TEXT and cell display, 14 locales) are a shared service in the core package.
using RecursiveAI.OneDocument.Spreadsheets;
using RecursiveAI.OneDocument.Spreadsheets.Streaming;

[SpreadsheetRow(Sheet = "Orders")]
public partial record Order(int Id, string Customer, decimal Total);

Spreadsheet.Write("orders.xlsx", orders);                       // or .csv, .tsv
foreach (Order o in Spreadsheet.Read<Order>("orders.xlsx")) { }  // lazy, streaming

using var wb = Workbook.Open("sales.xlsx");
wb.Sheets[0]["B2"].SetNumber(1200);
wb.Save();                                    // atomic replace; only the edited sheet part changes

using XlsxStreamReader book = XlsxStreamReader.Open("big.xlsx");
using SheetCursor sheet = book.OpenSheet(0);
while (sheet.ReadRow())
{
    while (sheet.ReadCell())
    {
        if (sheet.Kind == CellValueKind.Number) { total += sheet.Number; }
    }
}

See the repository for the support table and measurements, and the changelog.

Licensed MIT OR Apache-2.0, © Recursive AI, LLC. Not affiliated with Microsoft or with any other product or company named OneDocument.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on RecursiveAI.OneDocument.Spreadsheets:

Package Downloads
RecursiveAI.OneDocument.Rendering

Read, write, calculate, template and render Word, Excel and PowerPoint documents (OOXML, legacy binary, RTF, ODF) in pure .NET. Not affiliated with Microsoft. Layout and rendering of documents, workbooks and presentations to tagged PDF and PNG for OneDocument, with its own Office layout engine, charts, SmartArt, equations and metafile drawing.

RecursiveAI.OneDocument.All

Read, write, calculate, template and render Word, Excel and PowerPoint documents (OOXML, legacy binary, RTF, ODF) in pure .NET. Not affiliated with Microsoft. Metapackage that brings in every OneDocument package that has content (core, documents, spreadsheets, presentations, schema views and rendering).

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.0 0 11/6/2026

See CHANGELOG.md in the repository.