ByteScout PDF Renderer SDK - C# - Convert PDF To High Quality PNG - ByteScout

ByteScout PDF Renderer SDK – C# – Convert PDF To High Quality PNG

  • Home
  • /
  • Articles
  • /
  • ByteScout PDF Renderer SDK – C# – Convert PDF To High Quality PNG

How to convert PDF to high quality PNG in C# using ByteScout PDF Renderer SDK

This code in C# shows how to convert PDF to high quality PNG with this how to tutorial

Sample source code below will show you how to cope with a difficult task like convert PDF to high quality PNG in C#. What is ByteScout PDF Renderer SDK? It is the SDK for rendering of PDF into high-quality thumbnails and images. Includes various functions like batch processing, PNG, TIFF output. Can be used from web and desktop applications. It can help you to convert PDF to high quality PNG in your C# application.

The SDK samples like this one below explain how to quickly make your application do convert PDF to high quality PNG in C# with the help of ByteScout PDF Renderer SDK. Follow the instructions from the scratch to work and copy the C# code. Enjoy writing a code with ready-to-use sample codes in C#.

Free trial version of ByteScout PDF Renderer SDK is available on our website. Documentation and source code samples are included.

Try ByteScout PDF Renderer SDK today:  60 Day Free Trial (on-premise) or  Web API (on-demand version)

Program.cs
      
using System; using System.Diagnostics; using Bytescout.PDFRenderer; namespace PDF2PNG { class Program { static void Main(string[] args) { // Create an instance of Bytescout.PDFRenderer.RasterRenderer object and register it. RasterRenderer renderer = new RasterRenderer(); renderer.RegistrationName = "demo"; renderer.RegistrationKey = "demo"; // Set high quality resolution 600 dpi (600 dots per inch) float renderingResolution = 600; // Load PDF document. renderer.LoadDocumentFromFile("multipage.pdf"); for (int i = 0; i < renderer.GetPageCount(); i++) { // Render first page of the document to PNG image file. renderer.Save("image" + i + ".png", RasterImageFormat.PNG, i, renderingResolution); } // Cleanup renderer.Dispose(); // Open result document in default associated application (for demo purpose) ProcessStartInfo processStartInfo = new ProcessStartInfo("image0.png"); processStartInfo.UseShellExecute = true; Process.Start(processStartInfo); } } }

Try ByteScout PDF Renderer SDK today:  60 Day Free Trial (on-premise) or  Web API (on-demand version)

VIDEO

ON-PREMISE VERSION INFORMATION

Get 60 Day Free Trial or Visit ByteScout PDF Renderer SDK Home Page

Explore ByteScout PDF Renderer SDK Documentation

Get ByteScout PDF Renderer SDK Free Training

WEB API

Get Your Free API Key

Explore Web API Documentation

Tutorials:

prev
next