Convert MPP to PNG in Java

This concise topic focuses on how to convert MPP to PNG in Java. It provides well-defined configuration steps, and a working example code to demonstrate the capability. You can easily create an application to transform MPP file to PNG using Java with the help of a few API calls.

Steps to Convert MPP to PNG using Java

  1. Establish the environment to include Aspose.Tasks for Java using the repository manager to convert MPP to PNG using Java
  2. Access an existing MPP file using the Project class object to change MPP to PNG using Java
  3. Set the output PNG file options using the ImageSaveOptions class object
  4. Save MPP as PNG in Java using the save method

The above-mentioned steps encompass the complete configuration details and a stepwise procedure to convert MS Project to PNG using Java. The Project class object is created to access the source MPP file from the disk and then ImageSaveOptions class instance is used to set the output PNG file properties. The ImageSaveOptions class instance is not compulsory and can be excluded by using the default settings for the output PNG file while rendering.

Code to Save MPP as PNG in Java

This example demonstrates the feature to convert MPP to PNG using Java with the help of a simple API interface. The Project class object has overloaded constructors that can load the source file from the disk and also from sources like the Web or database using memory streams. The ImageSaveOptions class is used to customize the output PNG file by using setter methods like setFitContent, setResolution, setPageCount, setPages, setImageQuality, and setPixelFormat to name a few.

This example has enlightened us about the process to change MPP to PNG using Java. If you want to learn about the process of converting an MPP to a CSV file, refer to the article on convert MPP to CSV in Java.

 English