Written by Allen Wyatt (last updated February 18, 2020)
This tip applies to Word 97, 2000, 2002, and 2003
When you assign macros to a toolbar, you have the option to change the Name assigned to the macro on the toolbar. If you later want to change this name, you can display the Customize dialog box (right-click on the toolbar and choose Customize from the resulting Context menu) and then right-click on the toolbar button.
There is only one problem with this approach: The Name setting for the toolbar button is nothing more than the name that appears as text within the toolbar, if you choose to have text or text and image displayed in the toolbar. (This may sound a bit confusing, especially to a Word novice. It all has to do with the settings that you choose when first adding the macro to your toolbar or when you display the Modify Selection menu for the toolbar button.) What if you want to change the actual ToolTip that appears when you hover the mouse pointer over the toolbar button?
Unfortunately, there is no easy way to change the ToolTip from any menu you can display in Word. Again, the Name field in the Modify Selection menu only controls what is shown as text within the toolbar button; it does not affect the ToolTip. So what are you to do? The only thing you can do is modify the ToolTip text via VBA and modify it in that way. The following short macro will do the trick:
Public Sub FixToolTip() Const sToolTip As String = "My ToolTip Text" Const sTBName As String = "Standard" Const iBtnIdx As Integer = 5 CommandBars(sTBName).Controls(iBtnIdx).TooltipText = sToolTip End Sub
This macro only has to be run once, because Word remembers the new ToolTip text once it is set. All you need to do is change the values assigned to the three constants at the beginning of the macro:
If you ran the macro exactly as it appears above, then the fifth button from the left on the Standard toolbar would have the ToolTip text of "My ToolTip Text".
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 (1494) applies to Microsoft Word 97, 2000, 2002, and 2003.
Learning Made Easy! Quickly teach yourself how to format, publish, and share your content using Word 2013. With Step by Step, you set the pace, building and practicing the skills you need, just when you need them! Check out Microsoft Word 2013 Step by Step today!
You'd think that Word would be consistent, right? Wrong! Here's one example where Word is anything but consistent when it ...
Discover MoreYour macro, in the course of doing some processing, may create a directory that you later need to delete. Here's how to ...
Discover MorePart of the information that Word maintains about each of your documents is a summary statement, which you can define in ...
Discover MoreFREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)
Got a version of Word that uses the menu interface (Word 97, Word 2000, Word 2002, or Word 2003)? This site is for you! If you use a later version of Word, visit our WordTips site focusing on the ribbon 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