Written by Allen Wyatt (last updated November 17, 2021)
This tip applies to Word 2007, 2010, 2013, and 2016
Word allows you not only to edit macros, but also to edit built-in commands. You can replace or augment these commands with your own macros. You can perform the editing by following these steps:
Figure 1. The Macros dialog box.
Note:
WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (11698) applies to Microsoft Word 2007, 2010, 2013, and 2016. You can find a version of this tip for the older menu interface of Word here: Editing Word's Built-in Commands.
Do More in Less Time! Are you ready to harness the full power of Word 2013 to create professional documents? In this comprehensive guide you'll learn the skills and techniques for efficiently building the documents you need for your professional and your personal life. Check out Word 2013 In Depth today!
Macros are part of the document and template that are loaded into memory when you open a file. If you have "junk" macros ...
Discover MoreSpend any time creating Word macros, and sooner or later you will need to repeat some of your programming code a certain ...
Discover MoreDocuments consist of a series of paragraphs, arranged in the order in which you need them. What if you need to reverse ...
Discover MoreFREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
2022-03-03 07:46:35
I have followed your instructions to get this standard vba. I will work with this to see if I can put an "if block", if there is or isn't image files (inlineshapes) in the Word Doc. And then select the first image file in a loop, and Open the FormatPicture Menu and then perhaps use SendKeys to reduce the image resolution. I use this a lot and have failed to do a macro to automate this with just SendKeys.
[I have thought about having a helper word file to copy and paste image files to it and then back to the original file to try to get around the inability to compress images automatically with a macro, but not tried yet]
Sub FormatPicture()
'
' FormatPicture Macro
' Changes the picture scaling, size, and cropping information
'
Dialogs(wdDialogFormatPicture).Show
End Sub
Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.
Visit the WordTips channel on YouTube
FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
Copyright © 2023 Sharon Parq Associates, Inc.
Comments