NuGet Packages Required to Convert Word to PDF| Syncfusion
13 Aug 20266 minutes to read
Converting a Word Document to PDF
For converting a Word document into PDF, the following NuGet packages need to be installed in your application.
| Platform(s) | Package name | Package manager console command |
|---|---|---|
| , Console Application (Targeting .NET Framework) | Syncfusion.DocToPdfConverter.WinForms | Install-Package Syncfusion.DocToPdfConverter.WinForms |
| Syncfusion.DocToPdfConverter.Wpf | Install-Package Syncfusion.DocToPdfConverter.Wpf | |
| Syncfusion.DocToPdfConverter.AspNet.Mvc5 | Install-Package Syncfusion.DocToPdfConverter.AspNet.Mvc5 | |
| , Console Application (Targeting .NET Core) and |
Syncfusion.DocIORenderer.Net.Core Note: Please refer to know about the NuGet packages that need to be installed to perform Word to PDF conversion in Linux OS. |
Install-Package Syncfusion.DocIORenderer.Net.Core |
|
|
Syncfusion.DocIORenderer.NET | Install-Package Syncfusion.DocIORenderer.NET |
TIPS
If you encounter issues while using the .NET Word library in ASP.NET Core, refer to the troubleshooting guide for recommended checks and solutions.
Retired Platforms
The following NuGet packages need to be included in your application based on the platform.
| Platform(s) | Package name | Package manager console command |
|---|---|---|
|
|
Syncfusion.DocToPdfConverter.AspNet | Install-Package Syncfusion.DocToPdfConverter.AspNet |
| Syncfusion.DocToPdfConverter.AspNet.Mvc4 | Install-Package Syncfusion.DocToPdfConverter.AspNet.Mvc4 | |
|
|
Syncfusion.Xamarin.DocIORenderer | Install-Package Syncfusion.Xamarin.DocIORenderer |
NOTE
- Starting with v16.2.0.x, if you reference Syncfusion® assemblies from trial setup or from the NuGet feed, you also have to add the “Syncfusion.Licensing” assembly reference and include a license key in your projects. Please refer to this link to know about registering the Syncfusion® license key in your application to use our components.
- Syncfusion® components are available in nuget.org
- Please refer the procedure to deploy your .NET Core application in Linux OS from here.
- From v32.1.19, the dependent package SkiaSharp is upgraded from 3.116.1 to 3.119.1 version and it is mandatory to use SkiaSharp.NativeAssets.Linux v3.119.1 and HarfBuzzSharp.NativeAssets.Linux v8.3.1.2 packages for converting Word documents into PDF in Linux environment.
- “DocIO supports Word to PDF conversion in a UWP application using DocIORenderer.” For further information, please refer here
- Syncfusion has deprecated the Syncfusion.DocToPdfConverter.AspNet package. We strongly recommend upgrading your applications to ASP.NET Core. Refer here to migrate from .NET Framework to .NET Core.
Additional NuGet packages required for Linux
The SkiaSharp and HarfBuzzSharp native asset NuGet packages are required as additional dependencies when deploying your application in Linux environments. There are two types of NuGet packages. Choose the appropriate ones based on your specific Linux environment.
Run one of the following commands in the Package Manager Console (or use dotnet add package for SDK-style projects):
// Common Linux distributions, Azure App Service, Google App Engine
Install-Package SkiaSharp.NativeAssets.Linux -Version 3.119.1
Install-Package HarfBuzzSharp.NativeAssets.Linux -Version 8.3.1.2// AWS Lambda, AWS Elastic Beanstalk (use the NoDependencies variant)
Install-Package SkiaSharp.NativeAssets.Linux.NoDependencies -Version 3.119.1The following table illustrates the native assets NuGet packages and their applicable Linux environments:
| Required Native assets NuGet packages | Applicable Linux environments |
|---|---|
|
SkiaSharp.NativeAssets.Linux v3.119.1 |
|
|
Converting Charts
The following NuGet package needs to be installed additionally to preserve a chart as image in Word to PDF conversion.
Note: The chart-to-image converter package is only required for .NET Framework targets (WinForms, WPF, ASP.NET MVC4, ASP.NET MVC5, and the retired ASP.NET). For ASP.NET Core, Blazor, WinUI, .NET MAUI, and Xamarin, the base
Syncfusion.DocIORenderer.Net.CoreorSyncfusion.DocIORenderer.NETpackage handles chart rendering natively and no additional chart package is needed.
| Platform(s) | Package name | Package manager console command |
|---|---|---|
| Windows Forms, Console Application (Targeting .NET Framework) | Syncfusion.OfficeChartToImageConverter.WinForms | Install-Package Syncfusion.OfficeChartToImageConverter.WinForms |
| WPF | Syncfusion.OfficeChartToImageConverter.Wpf | Install-Package Syncfusion.OfficeChartToImageConverter.Wpf |
| ASP.NET MVC5 | Syncfusion.OfficeChartToImageConverter.AspNet.Mvc5 | Install-Package Syncfusion.OfficeChartToImageConverter.AspNet.Mvc5 |
Retired Platforms (Charts)
The following NuGet packages need to be included in your application based on the retired platform.
| Platform(s) | Package name | Package manager console command |
|---|---|---|
|
ASP.NET |
Syncfusion.OfficeChartToImageConverter.AspNet | Install-Package Syncfusion.OfficeChartToImageConverter.AspNet |
| ASP.NET MVC4 | Syncfusion.OfficeChartToImageConverter.AspNet.Mvc4 | Install-Package Syncfusion.OfficeChartToImageConverter.AspNet.Mvc4 |
NuGet Package Installation and Uninstallation
To use Syncfusion® NuGet packages in your project, please refer the NuGet Package Installation and Uninstallation sections.
DocIO NuGet packages can be installed and uninstalled using Package Manager Console. In Visual Studio, select Tools > NuGet Package Manager > Package Manager Console and execute the following commands.
Windows Forms
NuGet Package: Syncfusion.DocToPdfConverter.WinForms
The package contains the DocToPdfConverter .NET library that allows you to convert the Word documents to PDF.
// Install package
Install-Package Syncfusion.DocToPdfConverter.WinForms// Uninstall package
Uninstall-Package Syncfusion.DocToPdfConverter.WinForms -RemoveDependenciesNuGet Package: Syncfusion.OfficeChartToImageConverter.WinForms
The package contains OfficeChartToImageConverter .NET library for converting the chart present in word document to image.
// Install package
Install-Package Syncfusion.OfficeChartToImageConverter.WinForms// Uninstall package
Uninstall-Package Syncfusion.OfficeChartToImageConverter.WinForms -RemoveDependenciesWPF
NuGet Package: Syncfusion.DocToPdfConverter.Wpf
The package contains the DocToPdfConverter .NET library that allows you to convert the Word documents to PDF.
// Install package
Install-Package Syncfusion.DocToPdfConverter.Wpf// Uninstall package
Uninstall-Package Syncfusion.DocToPdfConverter.Wpf -RemoveDependenciesNuGet Package: Syncfusion.OfficeChartToImageConverter.Wpf
The package contains OfficeChartToImageConverter .NET library for converting the chart present in word document to image.
// Install package
Install-Package Syncfusion.OfficeChartToImageConverter.Wpf// Uninstall package
Uninstall-Package Syncfusion.OfficeChartToImageConverter.Wpf -RemoveDependenciesASP.NET MVC5
NuGet Package: Syncfusion.DocToPdfConverter.AspNet.Mvc5
The package contains the DocToPdfConverter .NET library that allows you to convert the Word documents to PDF.
// Install package
Install-Package Syncfusion.DocToPdfConverter.AspNet.Mvc5// Uninstall package
Uninstall-Package Syncfusion.DocToPdfConverter.AspNet.Mvc5 -RemoveDependenciesNuGet Package: Syncfusion.OfficeChartToImageConverter.AspNet.Mvc5
The package contains OfficeChartToImageConverter .NET library for converting the chart present in word document to image.
// Install package
Install-Package Syncfusion.OfficeChartToImageConverter.AspNet.Mvc5// Uninstall package
Uninstall-Package Syncfusion.OfficeChartToImageConverter.AspNet.Mvc5 -RemoveDependenciesASP.NET Core and Blazor
NuGet Package: Syncfusion.DocIORenderer.Net.Core
The package contains the DocIORenderer .NET portable library that allows you to convert the Word documents to PDF.
// Install package
Install-Package Syncfusion.DocIORenderer.Net.Core// Uninstall package
Uninstall-Package Syncfusion.DocIORenderer.Net.Core -RemoveDependenciesWindows UI Library (WinUI) and .NET Multi-platform App UI (.NET MAUI)
NuGet Package: Syncfusion.DocIORenderer.NET
The package contains the DocIORenderer .NET library that allows you to convert the Word documents to PDF.
// Install package
Install-Package Syncfusion.DocIORenderer.NET// Uninstall package
Uninstall-Package Syncfusion.DocIORenderer.NET -RemoveDependencies