PNG JPG BMP TIFF PPSM
Aspose.Slides for Java
PPSM

Merge PPSM Files in Java

Merge PPSM documents using Aspose.Slides for Java server-side APIs.

Merge PPSM Files Using Java

Use Aspose.Slides for Java to load multiple PPSM presentations, clone slides from one presentation into another, and save the merged file. You can install the aspose-slides package in a Maven-based project by adding the repository and dependency below.

Repository

<repository>
    <id>AsposeJavaAPI</id>
    <name>Aspose Java API</name>
    <url>https://releases.aspose.com/java/repo/</url>
</repository>

Dependency

<dependency>
    <groupId>com.aspose</groupId>
    <artifactId>aspose-slides</artifactId>
    <version>version of aspose-slides API</version>
    <classifier>jdk17</classifier>
</dependency>

Merge PPSM Files - Java

Presentation destinationPresentation = new Presentation("presentation1.ppsm");
try {
    Presentation sourcePresentation = new Presentation("presentation2.ppsm");
    try {
        for (ISlide slide : sourcePresentation.getSlides()) {
            destinationPresentation.getSlides().addClone(slide);
        }
    } finally {
        sourcePresentation.dispose();
    }

    destinationPresentation.save("merged-presentation.ppsm", SaveFormat.Ppsm);
} finally {
    destinationPresentation.dispose();
}
 

Steps for Merging PPSM Files in Java

A basic document merge with Aspose.Slides for Java APIs can be done with just a few lines of code.

  1. Load the destination PPSM file with the Presentation class.

  2. Load the source PPSM file with the Presentation class.

  3. Loop through the ISlide objects in the source presentation.

  4. Call addClone to add each source slide to the destination presentation.

  5. Call the save method with SaveFormat.Ppsm.

System Requirements

Before running the Java merge sample code, make sure that you have the following prerequisites.

  • Microsoft Windows, Linux, macOS, or another OS with a supported Java Runtime Environment.
  • Get the latest version of Aspose.Slides for Java from Maven.

About Aspose.Slides for Java API

Aspose.Slides for Java can read, write, manipulate, merge, and convert Microsoft PowerPoint and OpenDocument presentations to formats such as PDF, XPS, HTML, TIFF, and ODP. It is a standalone API and does not require Microsoft PowerPoint or OpenOffice.

Online PPSM Merger Live Demos

PPSM What is PPSM File Format?

Files with the `.PPSM` extension are macro-enabled slide show files created with Microsoft PowerPoint 2007 or later. A `PPSM` file opens as a slide show and can contain macros.

Read More

Other Supported Merging Formats

Using Java, you can also merge many other file formats including the ones listed below.

ODP (OpenDocument Presentation Format)
OTP (OpenDocument Presentation Template)
POT (PowerPoint 97–2003 Template)
POTM (PowerPoint Macro-Enabled Template)
POTX (PowerPoint Template)
PPS (PowerPoint Slide Show)
PPSX (PowerPoint Slide Show)
PPT (PowerPoint 97-2003 Presentation)
PPTM (Macro-enabled Presentation File)
PPTX (Open XML Presentation Format)