Class PlaySettings (PowerPoint VBA)

Contains information about how the specified media clip will be played during a slide show.

Set

To use a PlaySettings class variable it first needs to be instantiated, for example

Dim pss as PlaySettings
Set pss = ActiveWindow.RangeFromPoint.AnimationSettings.PlaySettings

The following procedures can be used to set variables of type PlaySettings: AnimationSettings.PlaySettings and EffectInformation.PlaySettings

ActionVerb

Returns or sets a string that contains the OLE verb that will be run when the specified OLE object is animated during a slide show.

The default verb specifies the action that the OLE object runs — such as playing a wave file or displaying data so that the user can modify it — after the previous animation or slide transition.

ActivePresentation.Slides(2).Shapes(2).AnimationSettings.PlaySettings.ActionVerb = "Edit"

HideWhileNotPlaying

Determines whether the specified media clip is hidden during a slide show except when it is playing.

The value of the HideWhileNotPlaying property can be one of these MsoTriState constants.

ActivePresentation.Slides(2).Shapes(2).AnimationSettings.PlaySettings.HideWhileNotPlaying = msoTrue

LoopUntilStopped

Determines whether the specified movie or sound loops continuously until either the next movie or sound starts, the user clicks the slide, or a slide transition occurs.

The value of the LoopUntilStopped property can be one of these MsoTriState constants.

ActivePresentation.Slides(2).Shapes(2).AnimationSettings.PlaySettings.LoopUntilStopped = msoTrue

Parent

Returns the parent object for the specified object.

PauseAnimation

Determines whether the slide show pauses until the specified media clip is finished playing.

For the PauseAnimation property setting to take effect, the PlayOnEntry property of the specified shape must be set to msoTrue. The value of the PauseAnimation property can be one of these MsoTriState constants.

ActivePresentation.Slides(2).Shapes(2).AnimationSettings.PlaySettings.PauseAnimation = msoTrue

PlayOnEntry

Determines whether the specified movie or sound is played automatically when it is animated.

Setting this property to msoTrue sets the Animate property of the AnimationSettings object to msoTrue. Setting the Animate property to msoFalse automatically sets the PlayOnEntry property to msoFalse. Use the ActionVerb property to set the verb that will be invoked when the media clip is animated. The value of the PlayOnEntry property can be one of these MsoTriState constants.

ActivePresentation.Slides(2).Shapes(2).AnimationSettings.PlaySettings.PlayOnEntry = msoTrue

RewindMovie

Determines whether the first frame of the specified movie is automatically redisplayed as soon as the movie has finished playing.

The value of the RewindMovie property can be one of these MsoTriState constants.

ActivePresentation.Slides(2).Shapes(2).AnimationSettings.PlaySettings.RewindMovie = msoTrue

StopAfterSlides

Returns or sets the number of slides to be displayed before the media clip stops playing.

For the StopAfterSlides property setting to take effect, the PauseAnimation property of the specified slide must be set to False, and the PlayOnEntry property must be set to True. The media clip will stop playing when the specified number of slides have been displayed or when the clip comes to an end — whichever comes first. A value of 0 (zero) specifies that the clip will stop playing after the current slide.

ActivePresentation.Slides(2).Shapes(2).AnimationSettings.PlaySettings.StopAfterSlides = 3