Thread: code request
View Single Post
  #7  
Old 20-12-2016, 08:23
mtracy mtracy is offline
Member
 
Join Date: Jun 2012
Location: Niceville, Florida
Posts: 31
Default Macro updated to include drop shadow effects

Private Sub GlobalMacroStorage_SelectionChange()
Dim s As Shape, effC As EffectContour, effDS As EffectDropShadow, effSh As ShapeRange, i As Long
Set s = ActiveShape
If Not s Is Nothing Then
If s.Effects.count > 0 Then
For i = 1 To s.Effects.count
If s.Effects(i).Type = cdrContour Then
Set effC = s.Effects(i).Contour
Set effSh = ActiveDocument.CreateShapeRangeFromArray(effC.ContourGroup, s)
effSh.AddToSelection
ElseIf s.Effects(i).Type = cdrDropShadow Then
Set effDS = s.Effects(i).DropShadow
Set effSh = ActiveDocument.CreateShapeRangeFromArray(effDS.ShadowGroup, s)
effSh.AddToSelection
End If
Next i
End If
End If
End Sub
__________________
Myron Tracy
Accent Signs
Reply With Quote