Please Note: This article is written for users of the following Microsoft Word versions: 2007, 2010, 2013, and 2016. If you are using an earlier version (Word 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Word, click here: Editing Word's Built-in Commands.
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.
Create Custom Apps with VBA! Discover how to extend the capabilities of Office 2013 (Word, Excel, PowerPoint, Outlook, and Access) with VBA programming, using it for writing macros, automating Office applications, and creating custom applications. Check out Mastering VBA for Office 2013 today!
You can open multiple documents at the same time in Word, and each document occupies its own document window. Here's a ...
Discover MoreWouldn't it be great if Word could execute a macro every time someone typed in a particular keyword or phrase? Word may ...
Discover MoreWhen creating macros, you often need to offer a series of choices to a user. This tip demonstrates how easy it is to ...
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 © 2024 Sharon Parq Associates, Inc.
Comments