Solved

MS Word 2010 reformat shapes with text. Need to change font and margins.

Posted on 2013-12-27
1
683 Views
Last Modified: 2013-12-31
I have several documents that have multiple "Call Out" Shapes with Text in each (Verdana) and default Margin settings.  What would be the relevent VBA code to go through and change each shape to:

Font = Calibri
Size = 11
No Margins
Size of Shape = 80%
0
Comment
Question by:Cook09
1 Comment
 
LVL 14

Accepted Solution

by:
DrTribos earned 500 total points
ID: 39743102
Here you go:
Sub ChangeCallOut()

Dim oShape As Shape

For Each oShape In ActiveDocument.Shapes
    If oShape.Type = msoCalloutOne Then
    
        With oShape
            'Font = Calibri
            .TextFrame.TextRange.Font.Name = "Calibri"
            'Size = 11
            .TextFrame.TextRange.Font.Size = 11
            'No Margins
            .TextFrame.MarginBottom = 0
            .TextFrame.MarginLeft = 0
            .TextFrame.MarginRight = 0
            .TextFrame.MarginTop = 0
            'Size of Shape = 80%
            .Height = oShape.Height * 0.8
            .Width = oShape.Width * 0.8
        End With
    End If
Next oShape
End Sub

Open in new window

0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
My experience with Windows 10 over a one year period and suggestions for smooth operation
This Experts Exchange video Micro Tutorial shows how to tell Microsoft Office that a word is NOT spelled correctly. Microsoft Office has a built-in, main dictionary that is shared by Office apps, including Excel, Outlook, PowerPoint, and Word. When …
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now