Bodu.Formats.Excel.Binary 1.0.0

dotnet add package Bodu.Formats.Excel.Binary --version 1.0.0
                    
NuGet\Install-Package Bodu.Formats.Excel.Binary -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="Bodu.Formats.Excel.Binary" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Bodu.Formats.Excel.Binary" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Bodu.Formats.Excel.Binary" />
                    
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 Bodu.Formats.Excel.Binary --version 1.0.0
                    
#r "nuget: Bodu.Formats.Excel.Binary, 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 Bodu.Formats.Excel.Binary@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=Bodu.Formats.Excel.Binary&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=Bodu.Formats.Excel.Binary&version=1.0.0
                    
Install as a Cake Tool

Bodu.Formats.Excel.Binary

API stability — Stable. The public API surface is committed; breaking changes are reserved for a major-version bump per SemVer.

A narrow, read-only reader for the Excel 97-2003 binary workbook format (BIFF8 / .xls). It exposes the raw cell values of each worksheet — strings, numbers, booleans, and errors — and nothing more. There is no formula evaluation, styling, charting, or date inference; turning a numeric cell into a date or a column into a record is the caller's job.

Built on Bodu.IO.Compound for the underlying container.

A workbook is opened as a disposable, read-only session that keeps the container open and reads each sheet on demand by seeking to the stream offset its bound-sheet record records, so a single sheet can be read without parsing the others and the whole workbook is never materialized. The primary surface is the forward-only ExcelWorksheetReader; a materialized, randomly addressable ExcelWorksheet is offered as a convenience.

using Bodu.Formats.Excel;

using ExcelBinaryWorkbook workbook = ExcelBinaryWorkbook.OpenRead(path);

foreach (ExcelWorksheetInfo sheet in workbook.Worksheets)
    Console.WriteLine($"{sheet.Index}: {sheet.Name} ({sheet.Visibility}, {sheet.Type})");

// Primary, low-allocation forward scan.
using ExcelWorksheetReader reader = workbook.OpenWorksheet("Data");
while (reader.TryReadCell(out ExcelCell cell))
{
    switch (cell.Kind)
    {
        case ExcelCellKind.String: /* cell.StringValue */ break;
        case ExcelCellKind.Number: /* cell.NumberValue */ break;
        case ExcelCellKind.Boolean: /* cell.BooleanValue */ break;
    }
}

// Convenience, materialized random access.
ExcelWorksheet data = workbook.ReadWorksheet("Data");
if (data.TryGetCell(11, 0, out ExcelCell rate)) { /* ... */ }

// A caller that knows a column holds dates can convert a numeric cell:
DateOnly date = ExcelSerialDate.FromSerialDate(rate.NumberValue!.Value);

For a numeric, time-series workload, ExcelBinaryReaderOptions can skip optional metadata work:

using ExcelBinaryWorkbook workbook = ExcelBinaryWorkbook.Open(stream, new ExcelBinaryReaderOptions
{
    ReadDocumentProperties = false,
    DetectDateFormats = false,
});

Records handled

BOF / EOF (substream boundaries), BOUNDSHEET8 (sheet directory, with lbPlyPos offset, sheet type, and hidden state), SST (+ CONTINUE for split strings), LABELSST, LABEL, NUMBER, RK, MULRK, BOOLERR, FORMULA (cached result, with a trailing STRING record for a string result), XF / FORMAT (number formats), DATEMODE, and DIMENSIONS. BLANK / MULBLANK and unrecognized records are skipped. Malformed records fail with ExcelBinaryFormatException.

Runnable samples

The repository ships an offline, dotnet run-able sample for this package — the workbook session and sheet directory, forward-only streaming over ~18,000 cells, the materialized worksheet surface, and format-classified serial-date decoding against a real committed fixture — under samples/Formats.Excel/.

Out of scope

Formulas, styles, charts, pivot tables, macros, named ranges, and writing .xls files.

Part of the Bodu utility library.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  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 (1)

Showing the top 1 NuGet packages that depend on Bodu.Formats.Excel.Binary:

Package Downloads
Bodu.Financial.ExchangeRates.Rba

Reserve Bank of Australia (RBA) historical exchange-rate provider for Bodu.Financial. Downloads and parses the RBA's published daily .xls files and serves them as Bodu.Financial.ExchangeRates.ExchangeRate values through IDatedRateProvider and IRateProvider, with an async range API and in-memory plus on-disk caching. Includes the dependency-injection registration extensions (AddRbaExchangeRates) that register the provider as a singleton backed by a configured HttpClient and bind RbaRateProviderOptions through Microsoft.Extensions.Options.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.0 54 9/24/2026
0.7.0 120 9/24/2026
0.6.0 64 9/24/2026
0.5.0 73 9/23/2026