07-18-2003, 08:44 AM
What I want to do is use my form to retrieve First name, Last name, UserID, Phone # from the global address book for given users. For example if I were to type Doe, John in a text1 on my form and hit a command1 button, I'd want his phone # displayed in text2. I'm trying to learn how to do. Please show me what the code would look like.
07-18-2003, 08:52 AM
You need a reference from your VB project to Outlook Library.
Then you can use code like:
Set GAL = mapi.AddressLists("Global Address List")
for each addr in GAL.AddressEntries
MsgBox addr.Name & " " & addr.Address
BUT there are not many fields you can access. You might do better to study / search for the use of CDO, ADSI or LDAP and use one of these access methods instead.