CompuMaster.Excel.ClosedXml 2026.12.2

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

CompuMaster.Excel.ClosedXml

An MIT-licensed ClosedXML engine for the ExcelOps API on .NET Framework 4.8 and .NET 6 or later. It runs independently of Microsoft Excel.

Imports CompuMaster.Excel.ExcelOps
Imports CompuMaster.Excel.ExcelOps.ExcelDataOperationsBase
Imports CompuMaster.Excel.ExcelOps.ExcelDataOperationsOptions

Using workbook As New ClosedXmlExcelDataOperations(
    "input.xlsx", OpenMode.OpenExistingFile, New ExcelDataOperationsOptions(WriteProtectionMode.ReadOnly))
    Dim sheetName = workbook.WorkSheetNames()(0)
    workbook.WriteCellValue(sheetName, 0, 0, "Updated title")
    workbook.SaveCopyAs("output.xlsx", SaveOptionsForDisabledCalculationEngines.NoReset)
    Dim html = workbook.ExportSheetToHtml(sheetName, New HtmlSheetExportOptions()).ToString()
End Using

The adapter opens workbooks and templates from a path, byte array, or stream and saves them to .xlsx, .xlsm, .xltx, or .xltm. ExcelOps addresses are zero-based. The adapter exposes cell values, formulas, number formats, protection, merged ranges, column auto-fit, sheet visibility, sheet and cell selection, and worksheet copies between ClosedXML workbooks. Use CopyWorksheetFormulaMode.PreserveFormulas to copy formulas verbatim. Whole-sheet moves and Excel-compatible reference rewriting during copies require a different engine.

Structural row, column, and cell changes use ClosedXML's native reference updates. A request to disable these updates throws NotSupportedException. Reference updates follow ClosedXML's coverage. The adapter rejects structural changes in workbooks with charts by default because it cannot update chart references. Set AllowKnownStructuralReferenceDifferences to opt in to native changes in these workbooks. Recalculation uses ClosedXML's formula engine. Loading leaves stored formula results in place by default. Use FormulaCalculationMode.CalculateIfMissing to calculate a missing result explicitly. A request to recalculate a cell can also evaluate dirty formulas elsewhere in the workbook. Saving can persist cached results without calculation. Cached formula text containing characters invalid in XML raises NotSupportedException on save. A cache reset omits those results from the saved copy. Set AutoCalculationResetToEnabledForAllSavedWorkbooks = False to keep manual calculation mode in saved files. Use each workbook instance from one thread at a time.

HTML export uses the shared ExcelOps worksheet and workbook API. It supports worksheet ranges, configurable header rows, merged cells, formatted values, common font and alignment styles, direct RGB colors, and the shared export resource limits. HTML export cannot render pictures, charts, or conditional formatting. A request to include pictures or charts on a worksheet that contains them throws NotSupportedException.

Chart rendering, PDF export, printing, encrypted files, and the legacy binary workbook formats are outside the adapter's supported operations. Chart-sheet names can be listed. VBA support covers detecting, preserving, and removing existing projects. Call RemoveVbaProject() before converting a workbook to a macro-free file.

See the ClosedXML project for its Excel file and formula coverage.

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  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 was computed.  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. 
.NET Framework net48 is compatible.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2026.12.2 0 12/2/2026