PdfPig Getting Started

Help us to keep this website almost Ad Free! It takes only 10 seconds of your time:
> Step 1: Go view our video on YouTube: EF Core Bulk Insert
> Step 2: And Like the video. BONUS: You can also share it!

PdfPig is a NuGet library that allows users to read and extract text and other content from PDF files. It also helps you to create simple PDF documents containing text and geometrical shapes.

Features

  • Extracts the position and size of letters from any PDF document. This enables access to the text and words in a PDF document.
  • Allows the user to retrieve images from the PDF document.
  • Allows the user to read PDF annotations, PDF forms, embedded documents, and hyperlinks from a PDF.
  • Provides access to metadata in the document.
  • Exposes the internal structure of the PDF document.
  • Creates PDF documents containing text and path operations.
  • Read content from encrypted files by providing the password.

Installation

You can easily install it from the Package Manager Console window by running the following command.

PM> Install-Package PdfPig

Environment Setup

To start using the PdfPig in your application, you will need to install the PdfPig NuGet package.

Let's open the Visual Studio and create a new project.

image

Select the Create a new project option.

image

Choose C# as language, Windows as a platform, and Console as the project type. In the template pane, select Console Application and click the Next button.

image

Enter the project name, you can change the location and solution name, but we will leave it and click on the Next button.

image

On the Additional Information dialog, select the target framework and then click on the Create button.

image

You can see a new console application project is created. Now, to install a PdfPig, right-click on the project in Solution Explorer, and select Manage NuGet Packages...

image

Select the Browse tab and search for PdfPig and install the latest version by pressing the Install button.

image

Once PdfPig has been successfully installed. You are now ready to start your application.



Got any PdfPig Question?