MS Access

Using Hyperlink Fields

In this lesson, you will learn about how to use hyperlinks in Microsoft Access. A hyperlink can point to any file on your computer, on the network, or even on a Web page on the Internet. Whenever you click on a hyperlink, you jump to the hyperlink's destination (if it's available).

A hyperlink is usually indicated by colored and underlined text. If you have ever been on the World Wide Web, you've used hyperlinks all the time to move between different Web pages.

The Insert Hyperlink dialog box.

Microsoft recognized the importance of the Internet and thus introduced the new hyperlink field type in Access 2003. You can use the hyperlink field to store clickable links to files on your computer or network or to Web pages on the Internet.

In this lesson you will learn how to use to create links that point to files on your network or on the Internet.

  1. Select the tblTours table and click the Design button.

    First we need to add a hyperlink field to this table.

  2. Click the first blank Field Name row and type Link. Click the Data Type list arrow and select Hyperlink from the list.

    You've just created a hyperlink field!

  3. Save your changes and then click the View button on the toolbar to display the table in Datasheet view.

    Let's try adding a hyperlink to the Western Canada record.

  4. Click in the Link field for the Western Canada record and click the Insert Hyperlink button on the toolbar.

    Another way to insert a hyperlink is to select Insert » Hyperlink from the menu.

    The Insert Hyperlink dialog box appears, as shown in figure. This is where you will specify the name and location of the file or Web page you want to add as a hyperlink. If you know the location and name of the file or Web address, you can type it directly in the dialog box; otherwise, you can use the Browse button to locate the file.

  5. Click the Browse for File button.

    The Link to File dialog box appears and displays a list of files that you can use as the destination for your hyperlink.

  6. Browse to your Practice folder, then find and double-click the Canada Memo document.

    The Link to File dialog box closes, and the name and location of the Canada Memo is added to the Address box.

  7. Click OK.

    The dialog box closes and you return to the datasheet. Notice that the text "Canada Memo.doc" appears blue and underlined, signifying that it's a hyperlink. Let's see how our new hyperlink works.

  8. Click the Canada Memo.doc hyperlink.

    You immediately jump to the hyperlink's destinationin this case, the Canada Memo document.

    If a dialog box appears, warning you that hyperlinks can be harmful to your computer and data, click Yes to continue.

  9. Close Microsoft Word without saving any changes.

    You should be back in Microsoft Access, looking at the tblTours datasheet.

    Once you create a hyperlink, you can easily edit it to change its title or target, copy it, or delete it by right-clicking the hyperlink.

  10. Right-click the Canada Memo.doc hyperlink and select Hyperlink from the shortcut menu.

    A shortcut menu with the most frequently used hyperlink commands appears. Here you could select "Edit Hyperlink" to change the hyperlink's target or "Display Text" to edit the hyperlink's title. Your hyperlink is fine the way it is, so close the shortcut menu.

  11. Click anywhere in the datasheet to close the shortcut menu. Close the tblTours table without saving any changes.

To create a hyperlink field:

  1. display the table in design view.

  2. create a new field to store the hyperlinks.

  3. click the new hyperlink field's data type box, click the list arrow, and select hyperlink.

  4. save the table.

to insert a hyperlink:

  1. select the hyperlink field and click the insert hyperlink button on the toolbar.

    or...

    select the hyperlink field and select insert » hyperlink from the menu.

  2. either select a file you want (use the browse button to help you locate the file) or type a web address for the hyperlink's destination and click ok.

to edit a hyperlink:

  • right-click the hyperlink and select hyperlink » edit hyperlink from the shortcut menu.