Inserting Links and Cross-References to Pages in Doclets

Use Microsoft Word bookmarks to link to and cross-reference page numbers in your doclet. You can cross-reference bookmarks as page numbers in a table of contents doclet, whether you inserted the cross-references manually or inserted a manual table of contents and edited the cross-references. If the page number containing the bookmark changes, then the page number cross-references also change.

This topic describes inserting the bookmarks and then the cross-references. The procedures can also be used to edit a manual table contents.

Inserting Bookmarks

Before you add a cross-reference or a link, you must insert a bookmark at the location that you want to link to.

To insert a bookmark:

  1. In a Word document, place your cursor at the location of the bookmark.

  2. In the Insert ribbon, select Bookmark icon.

  3. In Bookmark Name, enter EPRCS_ and a bookmark identifier. For example, EPRCS_Fin_Review.

    Bookmark dialog box
  4. Click Add.

    The bookmark is created.

Inserting Page Number Cross-References or Links in Doclets

After you create the target bookmark, you can insert a page number cross-reference or a link to that bookmark in the document that you want to link from.

To insert page number cross-references:

  1. In the document to link from, place the cursor where you want the cross-reference. In this example, we will add a page number cross-reference in the table of contents.

    screenshot showing cross-reference insertion point
  2. Press Ctrl+F9 to insert field brackets. Ensure that the insertion point stays between the brackets.

    screenshot showing field brackets
  3. Enter pageref, followed by a space and then the bookmark name. For example, pageref EPRCS_Fin_Review.

    screenshot showing bookmark name entered
  4. Upload and check the source and target doclets back into the report package.

  5. On the Preview tab, select Actions, and then Download Preview to see the page cross-reference.

  6. In the downloaded report package preview in Word, you must refresh the page reference field to reflect the page number.


    Word may display ‘Error! Bookmark not defined’.

    screenshot showing page reference needs to be refreshed
  7. Press F9 to refresh the field information.


    The field is updated to reflect the page number in the report package where you inserted the bookmark in the doclet.

    screenshot showing inserted page number

To insert links:

  1. Highlight the text to add the link to, and then right-click and select Hyperlink.

    screenshot showing hyperlink menu
  2. In the Insert Hyperlink dialog box, for Address, enter #, followed by the bookmark name. For example, #EPRCS_Fin_Review.

    screenshot showing Insert Hyperlink dialog box
  3. The link is added to the text that you selected. In this example, the link was added to the Income Analysis text.

    screenshot showing link
  4. Upload and check the doclet back into the report package.

  5. On the Preview tab, select Actions, and then Download Preview to see the link.

  6. Click the link to navigate to the bookmark location.

    screenshot showing link target