calling up a outlook contact from external program 
Author Message
 calling up a outlook contact from external program

I want to call an outlook contact directly from another
program (using either the address book or outlook) by the
name. How do I reference the contact?


Thu, 14 Jul 2005 23:21:15 GMT  
 calling up a outlook contact from external program
Try this code; you can reference the Contact in the MAPIFolder.Items
collection by the Subject property, which for Contacts is the same as the
FullName property.

Function GetContactByName() As Outlook.ContactItem
    Dim objContactFolder As Outlook.MAPIFolder
    Dim objMyContact As Outlook.ContactItem

    Set objContactFolder =
Application.GetNamespace("MAPI").GetDefaultFolder(olFolderContacts)
    Set GetContactByName = objContactFolder.Items("Eric Legault")
End Function

--
Eric Legault, MCSD
ADAPSYS - http://www.adapsys.ca


Quote:
> I want to call an outlook contact directly from another
> program (using either the address book or outlook) by the
> name. How do I reference the contact?



Fri, 15 Jul 2005 23:35:26 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Programming Outlook Contact Activity Tab

2. Need a pause when calling an external program!

3. call external program from vb application

4. Calling an external program (and waiting until it's finished)

5. calling external program with extracted shape data

6. Call an external program

7. Call external program

8. Calling an external Program from VB6 with Parameters

9. calling external .exe program from VB

10. Newbie: Help with calling an external EXE program

11. Call external program and get results?

12. how to call an external program ?

 

 
Powered by phpBB® Forum Software