>I have a VFP form that automates Outlook, but i can't figure out how to make Address List available to the user.
>
>
>Thanks.
>Sergio
I would suggest you use functionality that is already there. You can create you new message, fill in known values (subject, body) and let the user select the adressee as they regularly do by displaying the message window with the Display method. Anyway, here is a sample of how you can access the OL global adress list:
SET SAFETY OFF
CREATE TABLE getlist (name C(50))
oOlApp = CREATEOBJECT("Outlook.Application")
IF TYPE("oOlApp") # "O"
MESSAGEBOX("Could not start Outlook!")
RETURN
ENDIF
oNameSpace = oOlApp.GetNameSpace("MAPI")
oAddressList = oNameSpace.AddressLists("Global Address List")
oAddressEntries = oAddressList.AddressEntries
FOR EACH oAddressEntry IN oAddressEntries
INSERT INTO getlist VALUES (oAddressEntry.Name)
ENDFOR