Convert PPTX to PPT in Python
Overview
This article explains how to convert PowerPoint Presentation in PPTX format into PPT format using Python. The following topic is covered.
- Convert PPTX to PPT in Python
Python Convert PPTX to PPT
For Python sample code to convert PPTX to PPT, please see the section below i.e. Convert PPTX to PPT. It just loads the PPTX file and saves in PPT format. By specifiying different save formats, you can also save PPTX file into many other formats like PDF, XPS, ODP, HTML etc. as disscussed in these articles.
- Python Convert PPTX to PDF
- Python Convert PPTX to XPS
- Python Convert PPTX to HTML
- Python Convert PPTX to ODP
- Python Convert PPTX to Image
Convert PPTX to PPT
To convert a PPTX to PPT simply pass the file name and save format to the Save method of Presentation class. The Python code sample below converts a Presentation from PPTX to PPT using default options.
import aspose.slides as slides
# Instantiate a Presentation object that represents a PPTX file
pres = slides.Presentation("presentation.pptx")
# Saving the PPTX presentation to PPT format
pres.save("presentation.ppt", slides.export.SaveFormat.PPT)