Examples:
The following VBA example applies predefined outline styles to selected objects. The style that is applied depends on the type of shape selected; for example, if the shape is a rectangle, the first preset outline style is applied to the outline of the rectangle. Only shapes that have an outline are included the selection.
Sub StylesOutline()
Dim s As Shape
For Each s In ActiveSelection.Shapes
If s.Outline.Type = cdrOutline Then
Select Case s.Type
Case cdrRectangleShape
s.Outline.Style = OutlineStyles(1)
Case cdrEllipseShape
s.Outline.Style = OutlineStyles(2)
Case cdrPolygonShape
s.Outline.Style = OutlineStyles(3)
End Select
End If
Next s
End Sub