會傳回動畫行為的 RotationEffect 物件。 唯讀。
語法
expression。 RotationEffect
詞 一個代表 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
另請參閱
支援和意見反應
有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應。