Class AnimationPoint (PowerPoint VBA)

The class AnimationPoint represents an individual animation point for an animation behavior. The AnimationPoint object is a member of the AnimationPoints collection. The AnimationPoints collection contains all the animation points for an animation behavior.


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

Dim apt as AnimationPoint
Set apt = ActivePresentation.SlideMaster.TimeLine.MainSequence(1).Behaviors(1).PropertyEffect.Points(Index:=1)

The following procedures can be used to set variables of type AnimationPoint: AnimationPoints.Item, AnimationPoints.Add and PropertyEffect.Points


Deletes the specified AnimationPoint object.



Returns or sets a String that represents a formula to use for calculating an animation.

ActiveWindow.Selection.SlideRange(1).TimeLine.MainSequence(1).Behaviors(1).PropertyEffect.Points(1).Formula = RGB(Red:=255, Green:=255, Blue:=255)


Returns the parent object for the specified object.


Sets or returns the time at a given animation point.

The value of the Time property can be any floating-point value between 0 and 1, representing a percentage of the entire timeline from 0% to 100%. For example, a value of 0.2 would correspond to a point in time at 20% of the entire timeline duration from left to right.

ActiveWindow.Selection.SlideRange(1).TimeLine.MainSequence(1).Behaviors(1).PropertyEffect.Points(1).Time = 0.2


Sets or returns the value of a property for an animation point. Read/write.

ActiveWindow.Selection.SlideRange(1).TimeLine.MainSequence(1).Behaviors(1).PropertyEffect.Points(1).Value = RGB(0, 255, 0)


Returns an AnimationPoint object that represents a new animation point.

Syntax : expression.Add (Index)

Index: The position of the animation point in relation to other animation points. The default value is -1, which means that if you omit the Index parameter, the new animation point is added to the end of existing animation points.

Dim apt As AnimationPoint
Set apt = ActivePresentation.SlideMaster.TimeLine.MainSequence(1).Behaviors(1).PropertyEffect.Points.Add()


Returns the number of objects in the specified collection.

Dim lngCount As Long
lngCount = ActiveWindow.Selection.SlideRange(1).TimeLine.MainSequence(1).Behaviors(1).PropertyEffect.Points.Count


Returns a single AnimationPoint object from the specified AnimationPoints collection.

Syntax : expression.Item (Index)

Index: The index number of the single AnimationPoint object in the collection to be returned.

Dim apt As AnimationPoint
Set apt = ActivePresentation.SlideMaster.TimeLine.MainSequence(1).Behaviors(1).PropertyEffect.Points(Index:=1)


Returns the parent object for the specified object.


Determines whether the transition from one animation point to another is smoothed.

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

ActiveWindow.Selection.SlideRange(1).TimeLine.MainSequence(1).Behaviors(1).PropertyEffect.Points.Smooth = msoTrue