Work With Slideshow Python

Work With Slideshow Python

This guide shows how to work with slideshow python using Aspose.Slides FOSS for Python.


Prerequisites

RequirementDetail
RuntimePython
Packageaspose-slides-foss
InstallSee the Installation guide

Steps

  1. Install the package:
pip install aspose-slides-foss
  1. Use the ISlideShowTransition class for the core operation.
import aspose.slides_foss as slides
from aspose.slides_foss.export import SaveFormat
from aspose.slides_foss.slideshow import TransitionType, TransitionSpeed

with slides.Presentation() as prs:
    transition = prs.slides[0].slide_show_transition
    transition.type = TransitionType.FADE
    transition.speed = TransitionSpeed.MEDIUM
    transition.advance_after = True
    transition.advance_after_time = 3000
    prs.save("slideshow.pptx", SaveFormat.PPTX)

Tips and Best Practices

  • Check the API reference for the latest class signatures
  • Handle file I/O exceptions when reading or writing files
  • Dispose of resources properly after use

Related Resources

See Also

 English