Home  Fees/Services  Access Examples  Tutorials  Access Download  Articles  Search  Contact  Privacy  Links
Custom Database Design Consultants
 
Access Programming Examples
 
Access Example Downloads
Access Application Object Examples

Application Object Method Examples
Methods for Controlling Access Objects

Access Tutorials>Application Object Methods> AddToFavorites



                                   
AccessError Method
AddToFavorites
BuildCriteria Method
CloseCurrentDatabase
CodeDB
CompactRepair Method
ConvertAccessProject


Access AddToFavorites Method Example

AddToFavorites Method - the AddToFavorites method adds the name of the current database to the Favorites folder. When applied to a Control object, the AddToFavorites method adds the hyperlink address contained in a control to the Favorites folder.

The AddToFavorites method has the same effect as clicking AddToFavorites on the Favorites menu on the Web toolbar when view a page on the internet.
Here is an example of adding to favorites the hyperlink contained in a control field on a form:

We add our Blue Claw Database Design url to the field called Field1 on the form.  This happens when the form loads in the Form Load event.  You could also allow the user to type in the hyperlink address or select it from a list.

Private Sub Form_Load()
    Me!Field1.HyperlinkAddress = "http://www.blueclaw-db.com/"
End Sub

Next, we add the link to our favorites list when the user clicks the Field1 hyperlink.


Private Sub Field1_Click()
    Me!Field1.Hyperlink.AddToFavorites
End Sub

Contact Information

Custom Software Development
Microsoft Access 2003 2000 2002(XP) 97 All Windows Versions