The Open XML SDK provides tools for working with Office Word, Excel, and PowerPoint documents. It supports scenarios such as:
- High-performance generation of word-processing documents, spreadsheets, and presentations.
- Populating content in Word files from an XML data source.
- Splitting up (shredding) a Word or PowerPoint file into multiple files, and combining multiple Word/PowerPoint files into a single file.
- Extraction of data from Excel documents.
- Searching and replacing content in Word/PowerPoint using regular expressions.
- Updating cached data and embedded spreadsheets for charts in Word/PowerPoint.
- Document modification, such as removing tracked revisions or removing unacceptable content from documents.
See the version list below for details.
Install-Package DocumentFormat.OpenXml -Version 2.9.0
dotnet add package DocumentFormat.OpenXml --version 2.9.0
<PackageReference Include="DocumentFormat.OpenXml" Version="2.9.0" />
paket add DocumentFormat.OpenXml --version 2.9.0
#r "nuget: DocumentFormat.OpenXml, 2.9.0"
// Install DocumentFormat.OpenXml as a Cake Addin #addin nuget:?package=DocumentFormat.OpenXml&version=2.9.0 // Install DocumentFormat.OpenXml as a Cake Tool #tool nuget:?package=DocumentFormat.OpenXml&version=2.9.0
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
## Version 2.9.0 - 2018-06-08
- `ListValue` now implements `IEnumerable<T>` (#385)
- Added a `WebExtension.Frozen` and obsoleted misspelled `Fronzen` property (#460)
- Added an `OpenXmlPackage.CanSave` property that indicates whether a platform supports saving without closing the package (#468)
- Simple types (except `EnumValue` and `ListValue`) now implement `IComparable<T>` and `IEquatable<T>` (#487)
- Removed state that was carried in validators that would hold onto packages when not in use (#390)
- `EnumSimpleType` parsing was improved and uses less allocations and caches for future use (#408)
- Fixed a number of spelling mistakes in documentation (#462)
- When calling `OpenXmlPackage.Save` on .NET Framework, the package is now flushed to the stream (#468)
- Fixed race condition while performing strict translation of attributes (#480)
- Schema data for validation uses a more compact format leading to a reduction in dll size and performance improvements for loading (#482, #483)
- A number of APIs are marked as obsolete as they have simple workarounds and will be removed in the next major change
- Fixed some constraint values for validation that contained Office 2007, even when it was only supported in later versions
- Updated `System.IO.Packaging` to 4.5.0 which fixes some issues on Xamarin platforms as well as minimizes dependencies on .NET Framework
## Version 2.8.1 - 2018-01-03
- Corrected package license file reference to show updated MIT License
## Version 2.8.0 - 2017-12-28
- Default runtime directive for better .NET Native support.
- Fixed part saving to be encoded with UTF8 but no byte order mark. This caused some renderers to not be able to open the generated document.
- Fixed exceptions thrown when errors are encountered while opening packages to be consistent across platforms.
- Fixed issue on Mono platforms using System.IO.Packaging NuGet package (Xamarin, etc) when creating a document.
- Fixed manual saving of a package when autosave is false.
- Fixed schema constraint data and standardized serialization across platforms.
- Upgraded to `System.IO.Packaging` version 4.4.0 which fixes some consistency with .NET Framework in opening packages.
## Version 2.7.2 - 2017-06-06
- Package now supports .NET 3.5 and .NET 4.0 in addition to .NET Standard 1.3 and .NET Framework 4.6
- Fixed issue where assembly version wasn't set in assembly.
## Version 2.7.1 - 2017-01-31
- Fixed crash when validation is invoked on .NET Framework with strong-naming enforced.
## Version 2.7.0 - 2017-01-24
- SDK now supports .NET Standard 1.3
- Moved to using System.IO.Packaging from dotnet/corefx for .NET Standard 1.3 and WindowsBase for .NET 4.5.
- Cleaned up project build system to use .NET CLI.
## Version 2.6.1 - 2016-01-15
- Added hundreds of XUnit tests. There are now a total of 1333 tests. They take about 20 minutes to run, so be patient.
## Version 2.6.0 - 2015-06-29
- Incorporated a replacement `System.IO.Packaging` that fixes some serious (but exceptional) bugs found in the WindowsBase implementation
- No dependencies.
- No dependencies.
- System.IO.Packaging (>= 4.5.0)
NuGet packages (368)
Showing the top 5 NuGet packages that depend on DocumentFormat.OpenXml:
ClosedXML is a .NET library for reading, manipulating and writing Excel 2007+ (.xlsx, .xlsm) files. It aims to provide an intuitive and user-friendly interface to dealing with the underlying OpenXML API.
The Open XML PowerTools provides guidance and example code for programming with Open XML Documents (DOCX, XLSX, and PPTX). It is based on, and extends the functionality of the Open XML SDK. It supports scenarios such as: •Splitting DOCX/PPTX files into multiple files. •Combining multiple DOCX/PPTX files into a single file. •Populating content in template DOCX files with data from XML. •High-fidelity conversion of DOCX to HTML. •Searching and replacing content in DOCX/PPTX using regular expressions. •Managing tracked-revisions, including detecting tracked revisions, and accepting tracked revisions. •Updating Charts in DOCX/PPTX files, including updating cached data, as well as the embedded XLSX. •Retrieving metrics from DOCX files, including the hierarchy of styles used, the languages used, and the fonts used. •Writing XLSX files using far simpler code than directly writing the markup, including a streaming approach that enables writing XLSX files with millions of rows.
SpreadsheetLight is an open source Open XML spreadsheet .NET library written in C#, and is released under the MIT License. You can create new Open XML spreadsheets, or work with existing Open XML spreadsheets that are compatible with Microsoft Excel 2007/2010/2013 and LibreOffice Calc. No Office/Excel Interop needed. You do not need Microsoft Office/Excel to be installed.
The runtime assemblies for libraries and applications that use Kentico API.
OxyPlot is a plotting library for .NET. This is package contains the OpenXML extensions.
GitHub repositories (37)
Showing the top 5 popular GitHub repositories that depend on DocumentFormat.OpenXml:
ZKEACMS build with .Net 5 (.Net CMS)可视化设计在线编辑内容管理系统
Open Source Graphical Programming for Design
Open Database Reporting Tool (.Net)
This repo contains .NET Portability Analyzer (VSIX and Console) libraries and tools