Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

Hyperlink.AddToFavorites Method (Access)

The AddToFavorites method adds a hyperlink address to the Favorites folder.

expression .AddToFavorites

expression A variable that represents a Hyperlink object.

Return Value

Nothing

When applied to a Control object, the AddToFavorites method adds the hyperlink address contained in a control to the Favorites folder.

The following example sets the HyperlinkAddress property of a command button. When the user clicks the command button, the address is added to the Favorites folder by using the AddToFavorites method.

To try this example, create a new form and add a command button named Command0. Paste the following code into the form's module. Switch to Form view and click the command button.

Private Sub Form_Load() 
 Me!Command0.HyperlinkAddress = "http://www.microsoft.com/" 
End SubPrivate Sub Command0_Click() 
 Me!Command0.Hyperlink.AddToFavorites 
End Sub
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.