Linked Collection Object

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I would like to be able to pick a contact from contact folder and then have
the linked contacts displayed in a list box for the picked contact.

I know how to do the first part. But I am not sure how to go about the link
object and how to display the linked contacts.

Thank you

Irene
I hope some one knows the answer
 
The Links collection in a ContactItem should be cast to a ContactItem object
so that you can retrieve the properties easily. Just pass your variable
holding a reference to your Contact item that contains links to a procedure
like this to iterate through them and retrieve Contact properties:

Sub ListLinkedContacts(SourceContact As Outlook.ContactItem)
Dim objLink As Outlook.Link, objContact As Outlook.ContactItem

For Each objLink In SourceContact.Links
Set objContact = objLink.Item
Debug.Print objContact.FullName
Next
End Sub
 
Back
Top