Import a Multi-frame TIFF file into a multi-page PDF page

We are trying to convert a multi frame TIFF image into a mutli PDF page.

I have figured out how to convert a tiff to a pdf. However, not sure how to iterate over the multipage tiff frames to create separate pages in single pdf.

thanks

@Goakes27,

You can convert multi-frame TIF to multi-page PDF document. Please try the following code example:

C#

// instantiate Document instance
Aspose.Pdf.Document doc = new Document();
// add blank page to pages collection of Document instance
doc.Pages.Add();
// as the image/TIFF file is in Landscape mode, so set page orientation accordingly
doc.PageInfo.IsLandscape = true;
// create Image object
Aspose.Pdf.Image image = new Aspose.Pdf.Image();
image.File = "c:/pdftest/multipage_tiff_example.tif";
// add image to paragraphs collection of PDF page
doc.Pages[1].Paragraphs.Add(image);
// save resultant file
doc.Save("c:/pdftest/multipage_tiff_example.pdf");

If this does not help, then kindly send us your source TIF file. We will investigate your scenario in our environment, and then share our findings with you.

Thanks, I did just find the same code moments ago LOL

I got it, tested it, and it works so Thanks Bunches!