Spire.PDF 9.11.4

.NET 6.0 .NET Core 2.0 .NET Framework 4.0
dotnet add package Spire.PDF --version 9.11.4
NuGet\Install-Package Spire.PDF -Version 9.11.4
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="Spire.PDF" Version="9.11.4" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Spire.PDF --version 9.11.4
#r "nuget: Spire.PDF, 9.11.4"
#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.
// Install Spire.PDF as a Cake Addin
#addin nuget:?package=Spire.PDF&version=9.11.4

// Install Spire.PDF as a Cake Tool
#tool nuget:?package=Spire.PDF&version=9.11.4

.NET Library for Processing & Manipulating PDF Files


Foo

Product PageDocumentationExamplesForumTemporary LicenseCustomized Demo

Spire.PDF for .NET is a professional PDF API applied to creating, writing, editing, handling and reading PDF files without any external dependencies within .NET ( C#, VB.NET, ASP.NET, .NET Core, .NET 5.0, MonoAndroid and Xamarin.iOS ) application.

Using this .NET PDF library, you can implement rich capabilities to create PDF files from scratch or process existing PDF documents entirely through C#/VB.NET without installing Adobe Acrobat.

PDF Processing Features

Conversions

Support Environment

  • Fully written in C# and also support VB.NET.
  • Applied on .NET Framework 2.0, 3.5, 3.5 Client Profile, 4.0, 4.0 Client Profile,4.5 and .NET Standard 2.0, .NET Core, .NET 5.0, MonoAndroid and Xamarin.Ios.
  • Support Windows Forms and ASP.NET Applications.
  • Support 32-bit OS
  • Support 64-bit OS
  • Support PDF Version 1.2, 1.3, 1.4, 1.5, 1.6 and 1.7.
  • PDF API reference in HTML.
  • Be Independent and do not need Adobe Acrobat or other third party PDF libraries.

Convert PDF to DOC in C#

            //Create a PDF document and load sample PDF.
            PdfDocument doc = new PdfDocument();
            doc.LoadFromFile("test.pdf");

            //Use SaveToFile method and set conversion target parameter as FileFormat.DOC.
            doc.SaveToFile("PDFtoDoc.doc", FileFormat.DOC);

Convert PDF to images in C#

            //Create a PDF document and load sample PDF.
            PdfDocument doc = new PdfDocument();
            doc.LoadFromFile("sample.pdf");

            Image bmp = doc.SaveAsImage(0);
            Image emf = doc.SaveAsImage(0, Spire.Pdf.Graphics.PdfImageType.Metafile);
            Image zoomImg = new Bitmap((int)(emf.Size.Width * 2), (int)(emf.Size.Height * 2));
            using (Graphics g = Graphics.FromImage(zoomImg))
            {
                g.ScaleTransform(2.0f, 2.0f);
                g.DrawImage(emf, new Rectangle(new Point(0, 0), emf.Size), new Rectangle(new Point(0, 0), emf.Size), GraphicsUnit.Pixel);
            }
            //Save as BMP
            bmp.Save("convertToBmp.bmp", ImageFormat.Bmp);
            System.Diagnostics.Process.Start("convertToBmp.bmp");

            //Save as EMF
            emf.Save("convertToEmf.png", ImageFormat.Png);
            System.Diagnostics.Process.Start("convertToEmf.png");

            //SAVE as ZoomImg
            zoomImg.Save("convertToZoom.png", ImageFormat.Png);
            System.Diagnostics.Process.Start("convertToZoom.png");

Convert HTML to PDF in C#

            //Create a pdf document.
            PdfDocument doc = new PdfDocument();

            PdfPageSettings setting = new PdfPageSettings();

            setting.Size = new SizeF(1000,1000);
            setting.Margins = new Spire.Pdf.Graphics.PdfMargins(20);

            PdfHtmlLayoutFormat htmlLayoutFormat = new PdfHtmlLayoutFormat();
            htmlLayoutFormat.IsWaiting = true;
            
            String url = "https://www.wikipedia.org/";
         
            Thread thread = new Thread(() =>
            { doc.LoadFromHTML(url, false, false, false, setting,htmlLayoutFormat); });
            thread.SetApartmentState(ApartmentState.STA);
            thread.Start();
            thread.Join();

            //Save pdf file.
            doc.SaveToFile("output-wiki.pdf");

Product PageDocumentationExamplesForumTemporary LicenseCustomized Demo

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  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-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp2.0 is compatible.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Framework net40 is compatible.  net403 was computed.  net45 was computed.  net451 was computed.  net452 was computed.  net46 was computed.  net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid is compatible. 
Xamarin.iOS xamarinios is compatible. 
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (6)

Showing the top 5 NuGet packages that depend on Spire.PDF:

Package Downloads
James.Testing.Pdf

A library of helpers for the purpose of testing pdf documents/content. It is named after the author who wrote the book of James in the Bible. (James 1:2-3)

Xe.Framework.All

Package Description

DynamicUtility

Package Description

Xe.Framework.PdfTools

Package Description

PdfExtractorNuget

Package Description

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
9.11.4 3,332 11/10/2023
9.11.0 1,718 11/3/2023
9.10.2 8,705 10/13/2023
9.9.9 8,662 9/21/2023
9.9.3 5,896 9/8/2023
9.8.5 13,719 8/10/2023
9.7.17 8,821 7/27/2023
9.7.14 7,083 7/20/2023
9.7.0 9,933 7/3/2023
9.6.0 24,155 6/5/2023
9.5.4 8,588 5/23/2023
9.4.12 11,917 4/28/2023
9.4.0 16,172 4/6/2023
9.3.4 21,936 3/15/2023
9.3.2 7,229 3/7/2023
9.2.6 18,912 2/15/2023
9.2.2 12,127 2/3/2023
9.1.0 46,242 1/5/2023
8.12.7 5,177 12/29/2022
8.12.5 10,842 12/14/2022
8.11.10 7,843 11/30/2022
8.11.2 22,960 11/16/2022
8.11.0 10,076 11/3/2022
8.10.5 8,369 10/19/2022
8.9.16 8,609 9/30/2022
8.9.2 10,255 9/14/2022
8.8.6 13,918 8/17/2022
8.7.9 15,077 7/27/2022
8.7.2 16,083 7/5/2022
8.6.1 23,456 6/8/2022
8.5.0 20,593 5/6/2022
8.4.15 16,495 4/21/2022
8.3.9 27,843 3/23/2022
8.2.2 32,402 2/22/2022
8.1.4 40,467 1/19/2022
8.1.0 27,859 1/6/2022
7.12.1 38,590 12/8/2021
7.11.1 60,663 11/9/2021
7.10.4 25,946 10/19/2021
7.10.0 7,146 10/9/2021
7.9.6 24,861 9/22/2021
7.9.2 13,812 9/2/2021
7.8.8 10,203 8/20/2021
7.8.2 15,512 8/4/2021
7.7.10 16,125 7/22/2021
7.6.15 15,936 6/29/2021
7.6.1 15,378 6/10/2021
7.5.0 15,703 5/7/2021
7.4.13 15,792 4/27/2021
7.4.5 30,249 4/14/2021
7.3.3 14,758 3/19/2021
7.3.1 6,618 3/12/2021
7.2.9 13,383 2/20/2021
7.2.5 10,083 2/7/2021
7.2.0 7,696 2/2/2021
7.1.10 12,317 1/15/2021
7.1.0 9,493 1/7/2021
6.12.20 6,164 12/25/2020
6.12.10 5,941 12/10/2020
6.12.3 5,965 12/7/2020
6.11.6 16,264 11/13/2020
6.11.0 5,842 11/4/2020
6.10.9 6,720 10/27/2020
6.10.4 8,740 10/20/2020
6.10.0 6,294 10/10/2020
6.9.16 12,893 9/28/2020
6.9.0 35,091 9/3/2020
6.8.5 24,009 8/17/2020
6.8.1 11,342 8/6/2020
6.7.12 10,191 7/29/2020
6.7.8 16,652 7/20/2020
6.7.6 6,114 7/8/2020
6.7.2 12,862 7/6/2020
6.5.15 22,784 5/28/2020
6.5.9 6,199 5/18/2020
6.5.6 26,942 5/13/2020
6.4.11 74,019 4/20/2020
6.4.4 7,505 4/10/2020
6.3.16 9,729 3/30/2020
6.3.10 22,572 3/23/2020
6.3.0 18,951 3/4/2020
6.2.6 10,407 2/19/2020
6.2.1 18,728 2/11/2020
6.1.8 28,244 1/21/2020
6.1.4 11,480 1/9/2020
5.12.15 20,631 12/16/2019
5.12.3 4,926 12/5/2019
5.11.18 5,739 11/29/2019
5.11.2 18,417 11/7/2019
5.11.0 6,055 11/1/2019
5.10.8 10,628 10/22/2019
5.10.2 9,965 10/11/2019
5.9.16 8,220 9/30/2019
5.9.6 6,850 9/18/2019
5.8.16 24,751 8/30/2019
5.8.7 20,896 8/13/2019
5.8.2 7,979 8/6/2019
5.7.20 5,236 7/31/2019
5.7.0 25,868 7/2/2019
5.6.31 3,357 7/1/2019
5.6.2 17,787 6/6/2019
5.5.21 10,893 5/24/2019
5.4.21 51,726 5/1/2019
5.4.20 3,336 4/29/2019
5.4.9 11,258 4/15/2019
5.4.1 9,903 4/4/2019
5.3.8 470,120 3/19/2019
5.3.2 5,713 3/11/2019
5.2.15 5,297 2/28/2019
5.2.3 5,927 2/14/2019
5.1.33 5,391 1/31/2019
5.1.16 5,523 1/19/2019
5.1.4 5,809 1/11/2019
5.1.0 9,160 1/2/2019
4.12.8 23,471 12/18/2018
4.12.2 8,305 12/7/2018
4.11.12 7,720 11/28/2018
4.11.8 33,260 11/16/2018
4.11.5 7,611 11/9/2018
4.11.3 23,352 11/8/2018