Table of contents
Collapse the table of content
Expand the table of content

Hyperlink.AddToFavorites Method (Access)

office 365 dev account|Last Updated: 6/12/2017
1 Contributor

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


expression. AddToFavorites

expression A variable that represents a Hyperlink object.

Return Value



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 = "" 
End SubPrivate Sub Command0_Click() 
End Sub

See also


Hyperlink Object

© 2018 Microsoft