PdfRasterizer.RasterizerProgress Event
Represents a progress event to inform about the number of pages rasterized.
public event ProgressChangedEventHandler PdfRasterizer.RasterizerProgress;
Public Event PdfRasterizer.RasterizerProgress As ProgressChangedEventHandler
Event Handler
Licensing Info
This event is a DynamicPDF Rasterizer feature. One of the following is required for non-evaluation usage:
- An active DynamicPDF Subscription
- An active DynamicPDF Professional or Professional Plus Subscription with DynamicPDF Rasterizer selected.
- A DynamicPDF Rasterizer for .NET v4.X Developer license.
Examples
This example demonstrates how to rasterize a PDF document.Imports System
Imports ceTe.DynamicPDF.Rasterizer
Module MyModule
Sub Main()
' Create a PdfRasterizer object.
Dim rasterizer As PdfRasterizer = New PdfRasterizer("InputPdfFile.pdf")
AddHandler rasterizer.RasterizerProgress, AddressOf RasterizerProgressing
' Save the image.
rasterizer.DrawToMultiPageTiff("Output.tif", TiffImageFormat.TiffWithLzw, ImageSize.Dpi72)
End Sub
Private Sub RasterizerProgressing(sender As Object, e As RasterizerProgressChangedEventArgs)
Console.WriteLine(e.PagesCompleted)
Console.WriteLine("pages have been rasterized")
End Sub
End Module
using System;
using ceTe.DynamicPDF.Rasterizer;
class MyClass
{
static void Main(string[] args)
{
// Create a PdfRasterizer object.
PdfRasterizer rasterizer = new PdfRasterizer("InputPdfFile.pdf");
rasterizer.RasterizerProgress += new ProgressChangedEventHandler(RasterizerProgressing);
// Save the image.
rasterizer.DrawToMultiPageTiff("Output.tif", TiffImageFormat.TiffWithLzw, ImageSize.Dpi72);
}
static void RasterizerProgressing(object sender, RasterizerProgressChangedEventArgs e)
{
Console.WriteLine(e.PagesCompleted + " pages have been rasterized");
}
}