View Single Post
  #1  
Old 01-09-2015, 14:45
ddonnahoe's Avatar
ddonnahoe ddonnahoe is offline
Senior Member
 
Join Date: Jan 2004
Location: Louisville, KY
Posts: 552
Send a message via ICQ to ddonnahoe Send a message via AIM to ddonnahoe Send a message via MSN to ddonnahoe Send a message via Yahoo to ddonnahoe
Default Macro for increasing and decreasing outline widths.

I created 2 sub for use in X7 that I can add shortcut keys to that will increase and decrease the outline widths of selected objects.

I'm wondering if anyone could look at my code and tell if there is anything i might do differently to streamline the code...

Code:
Sub OutlinesIncrease()
    Dim s As Shape
    
    ActiveDocument.unit = cdrPoint

    For Each s In ActiveSelection.Shapes.FindShapes()
        If s.CanHaveOutline Then
            If s.Outline.Width > 0 And s.Outline.Width < 1 Then
                s.Outline.Width = 1
            End If
            If s.Outline.Width > 1 Then
                s.Outline.Width = s.Outline.Width + 1
            End If
        End If
    Next s
End Sub

Sub OutlinesDecrease()
    Dim s As Shape
    
    ActiveDocument.unit = cdrPoint

    For Each s In ActiveSelection.Shapes.FindShapes()
        If s.CanHaveOutline Then
            If s.Outline.Width > 1 Then
                s.Outline.Width = s.Outline.Width - 1
            End If
        End If
    Next s
End Sub
__________________
Sean
Waiting for a ride in the T.A.R.D.I.S.
Reply With Quote