Microsoft has awarded Lene Fredborg, DocTools, the Microsoft MVP award for Word each year since 2008. Link to info about the MVP Award at DocTools - document automation - add-ins, macros and document templates for Microsoft Word (logo) Document Automation
Add-ins & Macros
Document Templates
For Microsoft Word
Document automation, templates, add-ins, macros, for Microsoft Word (graphic)

Bookmark this page | Tip a friend about DocTools


Custom Search

Macro ready for use...

Macro – Add Screen Tips to Text in Microsoft Word

Many users want to be able to make small screen tips in Word that work like the screen tips known from Websites, i.e. small boxes with information that appear when you hover the mouse over a text like here. For example, such screen tips may be used to show definitions of terms. Word has no functionality specifically for that but you can make use of the hyperlink functionality and obtain something similar. You can create such "screen tips hyperlinks" manually. However, this includes a number of steps: You must select text, add a bookmark with an appropriate name, create a hyperlink and enter the screen tip text, and format the text. Here you will find a set of macros that automate the process. One macro lets you add screen tips hyperlinks in a structured way and another one lets you easily remove a screen tip hyperlink again if you wish.

Terms of use

You are welcome to use the macros and Word tips provided on this website. The contents is copyright. You may not reproduce any of contents (with or without modification or credits) elsewhere on the web, or on CD. Please link to the contents on this website instead.

Please note that all free Word tips, macros, add-ins and demos are provided "as is" and without obligation. See also detailed Terms of use.

Instead of installing the macro solution available on this page you may be interested in the ready-to-use add-in DocTools ScreenTipManager.

Go to info about DocTools ScreenTipManager– advanced Word add-in
Go to info about macro for creating screen tips

Advanced Word add-in – Screen tips in Word – fast and easy with DocTools ScreenTipManager

DocTools ScreenTipManager - advanced add-in for Word

Free Trial - Try Before You Buy     Word add-in from DocTools

The add-in works with Microsoft Word 2010, 2013, 2016 on PC.

DocTools ScreenTipManager makes it fast and easy to create and edit screen tips in Word with up to 2040 characters. Screen tips you create using the free macro solution on this page are limited to 256 characters. The add-in also includes many other features.

You can access the functionality of the add-in from a custom tab in the Ribbon.

How to get the DocTools ScreenTipManager add-in

This advanced add-in is not free but the return on investment is almost immediate. It will make all your future work with screen tips fast and easy.

Click the button below to learn more about
DocTools ScreenTipManager or to buy the add-in.

You can try DocTools ScreenTipManager risk-free for 15 days.

READ MORE - See How it Works - 15-Day Free Trial

Top of page

How the screen tips macros work

The macro module you can download via the link below contains three macros:

  • AddScreenTipToText
  • GetBookmarName (used by the macro above)
  • RemoveScreenTipFromText

For easy access, you can assign keyboard shortcuts to the macros. Alternatively, you can assign the macros to a toolbar (Word 2003 and earlier versions) or the Quick Access Toolbar (QAT) (Word 2007 and later versions).

To add a screen tip hyperlink, select the relevant text, run the macro AddScreenTipToText. In the dialog box that opens, enter the text you want to appear in the screen tip. Click OK.

The text you entered will now appear in a screen tip when a user hovers the mouse over the text. Shading will be applied to the hyperlinked text in order to make it easy for the user to identify text with screen tips. The normal Hyperlink style will automatically be removed from the hyperlink so that the user can distinguish screen tip hyperlinks from ordinary hyperlinks. You can change the shading color in the macro if you wish.

If you wish to break your screen tip text into multiple lines, follow the instructions in the dialog box. In the example illustrated below, a screen tip with two lines of text is created.

To remove a screen tip, select the screen tip hyperlink or just click in it. Then run the macro RemoveScreenTipFromText.

Note that the screen tip text cannot exceed 256 characters.

For further details about how the macros work, please refer to the comments in the macros.

The illustration below shows the dialog box in which you specify the screen tip text. A sample text has been inserted:

The dialog box in which you must enter the desired screen tip text

The illustration below shows how screen tips hyperlinks will appear in the document. The displayed screen tip contains the text entered in the dialog box illustrated above:

How screen tips will appear in the document

Additional hints about how the screen tips work

You do not need to read the following in order to use the macros. However, it may help you understand how it works.

You only need the macros in order to add/remove screen tips hyperlinks. No macros need to be available to the end user of the document. This means that you can store the macros e.g. in your or in a global template placed in your Word Startup folder.

Since the screen tips are actually made as hyperlinks, you will find the standard hyperlink text "Ctrl + click to follow link" or "Click to follow link" at the bottom of the screen tips. That text cannot be removed. Whether "Ctrl + click" or only "Ctrl" is shown depends on whether or not the option Use Ctrl + click to follow hyperlink is turned on – here shown as it appears in Word 2003; in Word 2007 and 2010 you will find the option in the Word Options dialog, below the Advanced category:

Option that determines how to follow a hyperlink

The Word option for displaying screen tips must be turned on. In Word 2003, you will find the option here:
Tools > Options > View tab > Show group > Screen Tips.

In Word 2007, you will find the option here:
Office button > Word Options > Display category > Show document tooltips on hover.

In Word 2010, Word 2013 and Word 2016, you will find the option here:
File > Options > Display category > Show document tooltips on hover.

Note the screen tips are automatically turned on by the AddScreenTipToText macro. If the screen tips do not appear on a user's PC, ask the user to turn on the option on his/her PC.

The option must be turned on in order to display screen tips

In order to make the selection remain unchanged if a user Ctlr+clicks or clicks the hyperlink, a bookmark is added around the hyperlink itself and the hyperlink is defined to go to that bookmark, i.e. the cursor does not jump to another place.

Hyperlinks are fields. A field contains field code, i.e. instructions to Word about what to do. You can display the field codes by pressing Alt+F9. If you display field codes, you will see that the screen tips hyperlinks look as illustrated below. Note that formatting marks are shown so that you can se both the paragraph mark in the two-line screen tip and the spaces in the field code:

The field code of the screen tip hyperlink illustrated above

The field consists of these parts:

  • HYPERLINK is the field type.
  • \l tells Word to go to the bookmark named "_ScreenTip_4".
  • \o tells Word to display the text that follows as screen tip text.

Note that all the bookmarks created by the AddScreenTipToText macro are named "_SrceenTip_X" where X is a number. Bookmarks that start with an underscore are treated as hidden. If you open the Bookmark dialog box, you need to turn on Hidden bookmarks to see the bookmarks in the list. You cannot manually create hidden bookmarks. They can only be added programmatically. It you do not want the bookmarks to be hidden, you must change the macro code.

If you copy a screen tip hyperlink to another place in the same document, the copy points to the bookmark in the original screen tip since the bookmark name in the field code has not been changed. Thus, if a user clicks such copied screen tip hyperlink, the cursor will now jump to the original screen tip. The easiest way to correct this may be to remove the copied screen tip hyperlink using the RemoveScreenTipFromText macro and then create a new one using the AddScreenTipToText macro. The AddScreenTipToText macro always creates a uniquely named bookmark in the correct place.

Screen tips hyperlinks can only be seen in the Word document. For example, they will not appear if you create a PDF file.

Related information

See general information about VBA macros and code snippets, incl. information about how to install macros.

Top of page

Back to Macros...

BulletADD-INS Word add-ins ready for use - work smarter in Word

Copyright © 2006-2018 Lene Fredborg – DocTools ApS – all rights reserved | Microsoft Word Templates – add-ins – VBA macros | Save time and work more efficiently in Microsoft Word
Privacy policy | Terms of use | Cookies policy | Bookmark this page | Tip a friend | Links | Contact