PDF to PNG - pqScan.com
.NET PDF to PNG Converter .NET Software for Converting PDF into PNG Raster Image File Online Demo Download Trial Purchase Now

How to Convert PDF to PNG

back to home  >  .NET PDF to Image SDK  >  How to Convert PDF to Image in .NET  >  How to Convert PDF to PNG in .NET

The popularity of PDF file format is undeniable. However, in some circumstances, PDF file format is not suitable to accomplish task in .NET programming and you may need to change a large amount of pages in PDF document into .png image files. If so, why not try our PDF to Image Converter Library for .NET free testing package, the complete and affordable solution for your application. On this tutorial, you will know how to easily convert PDF into PNG images.

More About PDF

PDF, short for Portable Document Format, is one of the most popular file formats that could include and present text, fonts, graphics, and more on application operating systems, software, even on hardware which supports document presentation. It is also one of document formats that could be read directly by most popular desktop web browsers. A large amount of data is held by PDF on the Internet.

More About PNG

PNG, Portable Network Graphics, refers to a raster graphics file format, which was created to replace GIF (Graphics Interchange Format) image format. PNG image supports lossless data compression, and it is the most popular image format used on web.

Ready to Convert PDF to PNG in .NET

Here, we would like to show you how to convert PDF file into (PNG) images for your .NET applications or ASP.NET web sites. Before getting started, please make sure your development environment meets the following requirements.

  • Windows XP, Windows 7, Windows 8 in x86 or x64 platform
  • Windows Server 2003/2008/2012 in x86 or x64 platform
  • .NET Framework 2.0, 3.0, 3.5, 4.0 and 4.5
  • Microsoft Visual Studio 2005 and above versions
  • .NET WinForms project, Console application and ASP.NET web programming

Looking into Properties and APIs

PDF File Loading

You may easily load a PDF document to read into your .NET program by two means.

  1. Load and read a local PDF file.
  2. public bool LoadPDF(string fileName);
  3. Load and read PDF using stream. Both memory stream and file stream are supported.
  4. public bool LoadPDF(Stream stream);
If your PDF file loading is completed with no error, it will return true. And false is for wrong loading.

PDF Page Counting

pqScan .NET PDF to Image Component allows you to count and get the amount of PDF document pages in .NET project. Please use the code below to perform this function.

public int PageCount;

DPI (Dots per Inch) Setting

It's quite easy to change the rendered image definition via setting DPI property. Our .NET PDF to Image Conversion Library will render the output image according to user-defined DPI property.

public double DPI;

Obtain Page Size Detail

The original size of PDF document page can be obtained by using the codes below.

public int GetPageHeight(int pageIndex);
public int GetPageWidth(int pageIndex);

Control PDF to PNG Conversion

pqScan .NET PDF to Image SDK allows you to control the way of PDF to PNG conversion. For instance, you may choose to convert a certain page of PDF to PNG only. Of course, a range of PDF pages or the whole file can also be changed to PNG image files.

public Bitmap ToImage(int pageIndex);

Moreover, you can control and reset the rendered PNG image width and height.

public Bitmap ToImage(int pageIndex, int width, int height);
pqScan SDK
.NET PDF to Image Converter
Online Guide
How to Convert PDF to Image
Conversion Type
.NET Converter Lib: PDF to Multiple Pages TIF .NET Converter Lib: PDF to JPEG C# Converter Lib: PDF to Multiple Pages TIFF C# Converter Lib: PDF to GIF C# Converter Lib: PDF to TIFF VB.NET Converter Lib: PDF to Bitmap VB.NET Converter Lib: PDF to TIFF ASP.NET Converter Lib: PDF to Bitmap View All Image Types >>
My name is John Patel, just purchased your .NET PDF to Image SDK. Till now, it works brilliantly! Not only is incredibly easy to use, but also highly accurate and fast! It is obviously the best option for me. John Patel