Convert PUB to TIFF in C# | Publisher to TIFF Converter

Microsoft Publisher is a desktop publishing tool designed for crafting diverse publications, including newsletters, brochures, flyers, and more in the PUB format. Nevertheless, the PUB file format lacks broad compatibility. Therefore, there are instances when it becomes necessary to transform PUB files into TIFF images. In this article, we will learn how to convert PUB to TIFF in C#. We will furnish you with a comprehensive, step-by-step tutorial along with code examples to facilitate your journey.

This article covers the following topics:

  1. C# API to Convert PUB to TIFF
  2. Steps to Convert a PUB File to a TIFF
  3. Convert PUB to TIFF in C#
  4. Convert PUB to TIFF Online
  5. Free Learning Resources

C# API to Convert PUB to TIFF

Conversion of publisher PUB files into TIFF images can be done in two steps. Firstly, we will use the Aspose.PUB for .NET API to load and convert the PUB file into PDF format. After that, we will use the Aspose.PDF for .NET API to render the pages of the PDF file into TIFF images.

Please download the DLLs of the APIs or install them using the following NuGet commands:

PM> Install-Package Aspose.PUB
PM> Install-Package Aspose.PDF

How to Convert a PUB File to a TIFF

We can easily save a PUB file as a TIFF image by following the steps below:

  1. Create a PUB parser and parse the PUB file.
  2. Convert a PUB to a PDF file stream.
  3. Create a TIFF device and process PDF to save as TIFF.

Now, let’s see how to perform these steps in C# to convert a Publisher PUB file to a TIFF.

Convert PUB to TIFF in C#

Please follow the steps below to convert the Publisher file to a TIFF image programmatically in C#:

  1. Create a PUB parser using the CreateParser() method of the PubFactory class.
  2. Parse the loaded Publisher file using the Parse() method.
  3. Initialize the MemoryStream object to hold the PDF file.
  4. Convert PUB to PDF using the ConvertToPdf() method.
  5. Create an instance of the Document class with the PDF stream.
  6. Optionally, specify the TiffSettings.
  7. After that, create an instance of the TiffDevice with resolution and the TiffSettings object.
  8. Finally, call the Process() method to save the document as a TIFF.

The following code sample shows how to convert PUB to TIFF in C#.

Convert PUB to TIFF in C#

Convert PUB to TIFF in C#.

Get a Free License

You can get a free temporary license to try the libraries without evaluation limitations.

PUB to TIFF Converter - Free Online

You can try this free online PUB to TIFF Converter app to convert publisher files to TIFF images without installing any software or plugin.

PUB to TIFF – Learning Resources

Besides converting Publisher PUB files into TIFF format, you may also explore various other features of the library using the following resources:

Conclusion

In this blog post, we have shown you how to convert PUB to TIFF in C#. We have provided a step-by-step guide and code snippets to help you get started. Converting Publisher files to TIFF is a relatively simple task, and the code snippets provided in this blog post can be used as a starting point for developing your own Publisher to TIFF converter application. In case of any ambiguity, please feel free to contact us on our free support forum.

See Also