Convert PDF to OTP in Python
Import PDF pages and save them as a reusable OpenDocument presentation template with Aspose.Slides for Python via Java.
Convert PDF to OTP in Python
Aspose.Slides for Python via Java can import PDF pages as slides and save the resulting presentation as an OTP file. The OTP output is an OpenDocument presentation template that can be reused as the basis for new presentations.
Convert PDF to OTP using Python
Create an empty Presentation, remove its default slide, and call addFromPdf to import the PDF pages. Then call save with SaveFormat.Otp to create the OTP presentation template.
Python code for converting PDF to OTP
presentation = Presentation()
try:
presentation.getSlides().removeAt(0)
presentation.getSlides().addFromPdf("document.pdf")
presentation.save("presentation.otp", SaveFormat.Otp)
finally:
presentation.dispose()
How to convert PDF to OTP in Python
Follow these steps to import a PDF document and save its pages as a reusable OTP presentation template.
Install Aspose.Slides for Python via Java .
Configure the package and start the Java Virtual Machine in your application.
Import the PDF pages by calling
addFromPdfon the presentation’s slide collection.Call
savewithSaveFormat.Otpto create the OTP presentation template.
Convert PDF to Other Supported Formats
You can also convert PDF documents to other supported file formats.