AnimationBehavior.RotationEffect 属性 (PowerPoint)

返回动画动作的 RotationEffect 对象。 只读。

语法

expressionRotationEffect

表达 一个代表 AnimationBehavior 对象的变量。

返回值

RotationEffect

示例

以下示例向第一张幻灯片添加新的形状并设置旋转动画动作。

Sub AddRotation()

    Dim shpNew As Shape
    Dim effNew As Effect
    Dim aniNew As AnimationBehavior

    Set shpNew = ActivePresentation.Slides(1).Shapes _
        .AddShape(Type:=msoShape5pointStar, Left:=0, _
        Top:=0, Width:=100, Height:=100)

    Set effNew = ActivePresentation.Slides(1).TimeLine.MainSequence _
        .AddEffect(Shape:=shpNew, effectId:=msoAnimEffectCustom)

    Set aniNew = effNew.Behaviors.Add(msoAnimTypeRotation)

    With aniNew.RotationEffect
        'Rotate 270 degrees from current position
        .By = 270
    End With

End Sub

另请参阅

AnimationBehavior 对象

支持和反馈

有关于 Office VBA 或本文档的疑问或反馈? 请参阅 Office VBA 支持和反馈,获取有关如何接收支持和提供反馈的指南。