Merge PPTM files and export to PDF in Python
Combine macro-enabled PowerPoint presentations and save the merged slides as a PDF document with Aspose.Slides for Python via .NET. Microsoft PowerPoint and OpenOffice are not required.
Merge PPTM to PDF in Python
Aspose.Slides for Python via .NET
lets you merge PPTM presentations by cloning slides from a source Presentation into a destination Presentation. After combining the slides with SlideCollection.add_clone, call Presentation.save with SaveFormat.PDF to create a single PDF document.
Merge PPTM files to PDF using Python
Clone each source slide with SlideCollection.add_clone, then call Presentation.save with SaveFormat.PDF.
Python code to merge PPTM files into a single PDF document
with slides.Presentation("presentation1.pptm") as destination_presentation:
with slides.Presentation("presentation2.pptm") as source_presentation:
for slide in source_presentation.slides:
destination_presentation.slides.add_clone(slide)
destination_presentation.save("merged_presentation.pdf", slides.export.SaveFormat.PDF)
How to merge PPTM to PDF using Aspose.Slides for Python API
Follow these steps to merge two PPTM files and save the result as a single PDF document in Python.
Install Aspose.Slides for Python via .NET .
Import the
aspose.slidespackage.Open the destination and source PPTM files as
Presentationinstances.Clone each source slide by using
SlideCollection.add_clone.Save the merged presentation with
Presentation.saveandSaveFormat.PDF.
Export PPTM to Other Supported Formats
You can also merge PPTM files and export the result to other supported formats.