Skip to main content

PdfDocumentProcessor.CreateTiff(Stream, Int32, IEnumerable<Int32>) Method

Exports PDF pages to a multi-page TIFF image and writes the image to a stream.

Namespace: DevExpress.Pdf

Assembly: DevExpress.Docs.v24.1.dll

NuGet Package: DevExpress.Document.Processor


public void CreateTiff(
    Stream stream,
    int largestEdgeLength,
    IEnumerable<int> pageNumbers


Name Type Description
stream Stream

A stream to which the TIFF image should be written.

largestEdgeLength Int32

A length of the image’s largest dimension, in pixels.

pageNumbers IEnumerable<Int32>

A list of page numbers.


The largestEdgeLength parameter determines the output image height for pages with portrait orientation and width - for landscape pages.


The CreateTiff method is not available in .NET MAUI applications. An exception is thrown on an attempt to call this method.

The following example shows how to convert pages to a multi-page TIFF image.

using DevExpress.Pdf;

static void Main(string[] args)

  int largestEdgeLength = 1000;
  int[] pageNumbers = new int[] { 1, 3, 5 };

  using (PdfDocumentProcessor processor = new PdfDocumentProcessor())
    // Load a document.
    using (var stream = new FileStream("..\\..\\Image.tiff", FileMode.CreateNew, FileAccess.Write))
      // Export pages to a multi-page tiff image.
      processor.CreateTiff(stream, largestEdgeLength, pageNumbers);
See Also