Retrieving Outlook Contact Information:   Return to List

' A ContactItem can be identified by the Contact's "full name.
' The FullName property is the default property for a ContactItem:

Sub GetContactInfo()
Dim objOutlook As New Outlook.Application
Dim objContact As ContactItem
Dim objNameSpace As NameSpace
Dim objFolder As MAPIFolder
Set objNameSpace = objOutlook.GetNamespace("MAPI")
Set objFolder = objNameSpace.GetDefaultFolder(olFolderContacts)' The Contacts Folder
With objFolder.Items("John Doe")
    Debug.Print .HomeAddress' Print Home Address
    Debug.Print .HomeTelephoneNumber' Home Telephone Number
End With' for the Contact with the Name "John Doe"
Set objFolder = Nothing
Set objNameSpace = Nothing
Set objOutlook = Nothing
End Sub



Note to Webmaster