Timing.RepeatCount Property
Sets or returns the number of times to repeat an animation. Read/write.
Namespace: Microsoft.Office.Interop.PowerPoint
Assembly: Microsoft.Office.Interop.PowerPoint (in Microsoft.Office.Interop.PowerPoint.dll)
Syntax
'Declaration
Property RepeatCount As Integer
Get
Set
'Usage
Dim instance As Timing
Dim value As Integer
value = instance.RepeatCount
instance.RepeatCount = value
int RepeatCount { get; set; }
Property Value
Type: System.Int32
Long
Examples
This example creates a shape and adds an animation to it, then repeats the animation twice.
Sub AddShapeSetTiming()
Dim effDiamond As Effect
Dim shpRectangle As Shape
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)
With effDiamond.Timing
.Duration = 5 ' Length of effect.
.RepeatCount= 2 ' How many times to repeat.
End With
End Sub