深入探索Microsoft PowerPoint 2003的VB编程
1. 动画设置基础
在PowerPoint 2003中,利用Visual Basic可以实现丰富的动画效果。以下代码展示了如何创建一个自定义动画效果,改变形状的填充颜色:
Dim effCustom As Effect
Dim aniBehavior As AnimationBehavior
Dim aptNewPoint As AnimationPoint
Set sldNewSlide = ActivePresentation.Slides.Add _
(Index:=1, Layout:=ppLayoutBlank)
Set shpHeart = sldNewSlide.Shapes.AddShape _
(Type:=msoShapeHeart, Left:=100, Top:=100, _
Width:=200, Height:=200)
Set effCustom = sldNewSlide.TimeLine.MainSequence _
.AddEffect(shpHeart, msoAnimEffectCustom)
Set aniBehavior = effCustom.Behaviors.Add(msoAnimTypeProperty)
With aniBehavior.PropertyEffect
.Property = msoAnimShapeFillColor
Set aptNewPoint = .Points.Add
aptNewPoint.Time = 0.2
aptNewPoint.
超级会员免费看
订阅专栏 解锁全文
13

被折叠的 条评论
为什么被折叠?



