Timing.AutoReverse Property
Determines whether an effect should play forward and then in reverse, thereby doubling its duration. Read/write.
Namespace: Microsoft.Office.Interop.PowerPoint
Assembly: Microsoft.Office.Interop.PowerPoint (in Microsoft.Office.Interop.PowerPoint.dll)
Syntax
'Declaration
Property AutoReverse As MsoTriState
Get
Set
'Usage
Dim instance As Timing
Dim value As MsoTriState
value = instance.AutoReverse
instance.AutoReverse = value
MsoTriState AutoReverse { get; set; }
Property Value
Type: Microsoft.Office.Core.MsoTriState
MsoTriState
Remarks
The value of the AutoReverse property can be one of these MsoTriState constants.
Constant |
Description |
---|---|
msoFalse |
The default. The effect does not play forward and then in reverse. |
msoTrue |
The effect plays forward and then in reverse. |
Examples
The following example adds a shape and an animation effect to it; then it sets the animation to reverse direction after it finishes its forward movement.
Sub SetEffectTiming()
Dim effDiamond As Effect
Dim shpRectangle As Shape
'Adds rectangle and applies diamond effect
Set shpRectangle = ActivePresentation.Slides(1).Shapes.AddShape _
(Type:=msoShapeRectangle, Left:=100, _
Top:=100, Width:=50, Height:=50)
Set effDiamond = ActivePresentation.Slides(1).TimeLine _
.MainSequence.AddEffect(Shape:=shpRectangle, _
effectId:=msoAnimEffectPathDiamond)
'Sets the duration of and reverses the effect
With effDiamond.Timing
.Duration = 5 ' Length of effect.
.AutoReverse= msoTrue
End With
End Sub