Microsoft KB Archive/81456

{|
 * width="100%"|

Searching for Bookmark Cross Reference Codes in Word

 * }

Q81456

-

The information in this article applies to:


 * Microsoft Word for MS-DOS, versions 5.0, 5.x, 6.0

-

SUMMARY
In versions 5.0 and 5.5 of Microsoft Word for MS-DOS, the Search and Replace commands cannot locate bookmark names that have been set up as cross-reference codes.

For example, if you have a bookmark called BOOK1, you can create cross-reference codes in your text to reference the page your bookmark is on by typing your bookmark name followed by a colon and pressing F3. The cross-reference code appears as (BOOK1:). If you attempt to search for or replace the reference mark by searching for BOOK1, BOOK1:, or (BOOK1:), Word cannot locate any of the reference marks.

Manual Workaround
To work around this problem, use the following steps:


 * 1) Position the cursor where you want to insert a bookmark cross- reference code.
 * 2) Type the bookmark name twice, follow each name with a colon, and leave a space between the two names.
 * 3) Press F3 to format the second name as a cross-reference code. Parentheses appear around the reference code.
 * 4) Select the first name and format it as hidden text.
 * 5) Make sure that &quot;Show Hidden Text&quot; is set to yes in the Options menu in Word 5.0, and that &quot;Hidden Text&quot; is selected in the View Preferences dialog box of Word 5.5.

You can now search for the bookmark name followed by a colon to find each reference.

Macro Workaround
You can also use the following macro to work around this problem. Type in the cross-reference name. With the cursor resting in the space following the cross-reference name, run the macro.

Macro for Word 5.0
: 

Macro for 5.5
store:      restore

Description of Xref Macro
This macro assumes the following:


 * 1) The Store and Restore macros are in the open glossary.
 * 2) The Store and Restore macros are called.

Macro Text                     Description --                     ---

:                     copy it to scrap, and format the word as hidden text.

              Move right and insert the name again, press  to format as a                               bookmark.

Move to the space separating the restore               bookmark and the hidden text, and delete it. Additional query words:

Keywords : kbusage

Issue type : kbprb

Technology :