CommonNetFuncs.Word.OpenXml
3.6.26
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package CommonNetFuncs.Word.OpenXml --version 3.6.26
NuGet\Install-Package CommonNetFuncs.Word.OpenXml -Version 3.6.26
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="CommonNetFuncs.Word.OpenXml" Version="3.6.26" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="CommonNetFuncs.Word.OpenXml" Version="3.6.26" />
<PackageReference Include="CommonNetFuncs.Word.OpenXml" />
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 CommonNetFuncs.Word.OpenXml --version 3.6.26
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: CommonNetFuncs.Word.OpenXml, 3.6.26"
#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 CommonNetFuncs.Word.OpenXml@3.6.26
#: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=CommonNetFuncs.Word.OpenXml&version=3.6.26
#tool nuget:?package=CommonNetFuncs.Word.OpenXml&version=3.6.26
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
CommonNetFuncs.Word.OpenXml
This lightweight project contains helper methods related to MS Word formatted documents (.doc & .docx).
Contents
ChangeUrls
Helpers that search for and change URLs in .doc and .docx files.
Common Usage Examples
<details> <summary><h3>Usage Examples</h3></summary>
ChangeUrlsInWordDoc
Look for specific URLs in a word document and change them to a different URL.
FileStream stream = new(@"C:\Documents\UrlTest.docx");
bool success = ChangeUrls.ChangeUrlsInWordDoc(stream, "http://google.com", "http://yahoo.com", true); // Replaces all "yahoo.com" URLs in the document with "google.com"
// Alternatively, use a dictionary for replacements
Dictionary<string, string> urlsToUpdate = new()
{
{ "http://google.com", "http://yahoo.com" },
{ "http://facebook.com", "http://meta.com" },
{ "http://tumblr.com", "http://imgr.com" }
};
bool success = ChangeUrls.ChangeUrlsInWordDoc(stream, urlsToUpdate); // Replaces all key URLs in the dictionary with their associated value
ChangeUrlsInWordDocRegex
Look for URLs that match a regex pattern in a word document and replace the matched string with a new one.
FileStream stream = new(@"C:\Documents\UrlTest.docx");
bool success = ChangeUrls.ChangeUrlsInWordDoc(stream, @"^(http:\/\/)", "https://", true); // Replaces "http://" with "https://" in all URLs in the document
// Alternatively, use a dictionary for replacements
Dictionary<string, string> urlsToUpdate = new()
{
{ @"^(http:\/\/)", "https://" },
{ @"(yahoo\.com)", "google.com" }
};
bool success = ChangeUrls.ChangeUrlsInWordDoc(stream, urlsToUpdate); // Replaces all regex matches with the keys in the dictionary with their associated values
</details>
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net9.0 is compatible. 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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net9.0
- DocumentFormat.OpenXml (>= 3.3.0)
- NLog.Extensions.Logging (>= 6.0.3)
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 |
|---|---|---|
| 3.8.16 | 46 | 11/17/2025 |
| 3.8.13 | 259 | 11/10/2025 |
| 3.8.4 | 179 | 10/9/2025 |
| 3.7.17 | 175 | 9/11/2025 |
| 3.7.16 | 166 | 9/11/2025 |
| 3.7.13 | 178 | 9/8/2025 |
| 3.7.0 | 273 | 8/18/2025 |
| 3.6.27 | 168 | 8/18/2025 |
| 3.6.26 | 181 | 8/14/2025 |
| 3.6.25 | 182 | 8/13/2025 |
| 3.6.24 | 175 | 8/12/2025 |
| 3.6.19 | 162 | 7/28/2025 |
| 3.6.18 | 393 | 7/25/2025 |
| 3.6.6 | 513 | 7/21/2025 |
| 3.6.1 | 173 | 7/14/2025 |
| 3.6.0 | 195 | 7/14/2025 |
| 3.5.3 | 172 | 7/10/2025 |
| 3.5.0 | 182 | 7/7/2025 |
| 3.4.23 | 189 | 6/26/2025 |
| 3.4.21 | 171 | 6/26/2025 |
| 3.4.20 | 166 | 6/25/2025 |
| 3.4.18 | 176 | 6/23/2025 |
| 3.4.8 | 320 | 6/11/2025 |
| 3.4.2 | 182 | 6/2/2025 |
| 3.4.1 | 119 | 5/30/2025 |
| 3.4.0 | 132 | 5/30/2025 |
| 3.3.11 | 185 | 5/18/2025 |
| 3.3.10 | 266 | 5/13/2025 |
| 3.3.0 | 198 | 4/29/2025 |
| 3.2.20 | 273 | 3/7/2025 |
| 3.2.13 | 163 | 2/13/2025 |
| 3.2.9 | 143 | 2/4/2025 |
| 3.2.0 | 145 | 12/19/2024 |
| 3.1.0 | 217 | 12/6/2024 |
| 3.0.0 | 150 | 12/3/2024 |
| 2.1.3 | 143 | 12/3/2024 |
| 2.1.0 | 145 | 12/2/2024 |
| 2.0.5 | 144 | 11/26/2024 |
| 2.0.3 | 150 | 11/20/2024 |
| 2.0.2 | 145 | 11/18/2024 |
| 2.0.1 | 143 | 11/15/2024 |
| 2.0.0 | 139 | 11/14/2024 |
| 1.0.47 | 146 | 11/14/2024 |
| 1.0.42 | 152 | 11/12/2024 |
| 1.0.40 | 146 | 11/12/2024 |
| 1.0.37 | 153 | 11/6/2024 |
| 1.0.31 | 154 | 11/1/2024 |