• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL

Chapter 16. Working with Hyperlinks and ... > Using Hyperlinks with Access Control...

Using Hyperlinks with Access Controls

You can use hyperlinks with Access controls such as command buttons, combo boxes, and labels to jump to another document or open an object within the current or another Access database. To create a form with a command button to open Northwind.mdb's Orders form with a hyperlink, follow these steps:

Create a new form in Design view.

Disable the Control Wizards and add a command button to the form.

With the command button selected, click the Properties toolbar button to open the Properties window and click the Format tab.

In the Caption property text box, type Open Orders Form to create the display text component of the hyperlink.

Leave the Hyperlink Address property text box empty, specifying that the object you want to open is in the current database.

Select the Hyperlink Subaddress property text box and click the Builder button to open the Select Location dialog.

Click the Forms tab, select the Orders form, and then click OK. Form Orders appears in the Hyperlink Subaddress property text box, and the command button's caption appears underlined in blue type (see Figure 16.19).

Figure 16.19. A command button that uses a hyperlink to open a form in the current database.

Change to Form view and click the command button to open the Orders form.

Close, but don't save, your test form.


Using command buttons with hyperlinks to open forms lets you take advantage of Access 97's lightweight forms (forms without VBA code in class modules). You can open—but not close—a form with a hyperlink. As a result, users of your application may be confronted with a large number of simultaneously opened forms. Having more than two open forms at a time is likely to confuse users new to Access applications.



Not a subscriber?

Start A Free Trial

  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint