Hi Samuel:
This is what I use to get address from Outlook Contacts:
#DEFINE Contacts 10
WAIT WINDOW 'Building Address List...' NOWAIT NOCLEAR
LOCAL oNameSpace, oContacts
oOutlook = CREATEOBJECT('Outlook.Application')
oNameSpace = oOutlook.GetNameSpace('MAPI')
oContacts = oNameSpace.GetDefaultFolder(Contacts)
CREATE CURSOR ContactInfo ;
(address C(100), fname C(20), lname C(40))
FOR EACH oContact IN oContacts.Items
cAddr = oContact.Email1Address
cFname = oContact.FirstName
cLname = oContact.LastName
INSERT INTO ContactInfo (address, fname, lname) VALUES (cAddr, cFname, cLname)
ENDFOR
SELECT ContactInfo
SCAN
THISFORM.lstSelect.ADDITEM(ContactInfo.address)
ENDSCAN
RELEASE oOutlook
RELEASE oNamesSpace
RELEASE oContacts
THIS.REFRESH()
WAIT CLEAR
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only