Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to pull from and post data to Outlook
Message
De
10/10/2000 16:11:42
Larry Long
ProgRes (Programming Resources)
Georgie, États-Unis
 
 
À
10/10/2000 12:28:49
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00427281
Message ID:
00427530
Vues:
16
Never mind, I figured it out... Here's what I came up with...

****************
oOutlook=CREATEOBJECT("Outlook.Application")
oNameSpace=oOutlook.GetNameSpace("MAPI")
oContactsFolder=oNameSpace.GetDefaultFolder(10)
oContacts=oContactsFolder.Items
oFolders=oContactsFolder.Folders

strFilter = "[MessageClass] >= 'IPM.Contact' AND [MessageClass] <= 'IPM.Contact'"
oContacts = oContacts.Restrict(strFilter)

i=0
*SCAN THRU CONTACTS MAIN FOLDER
For each loContact in oContacts
i=i+1
With loContact
Wait window .CompanyName
Endwith
Endfor

*SCAN THRU CONTACTS SUBFOLDERS (IF ANY)
For each loFolder in oFolders
oContacts=oContactsFolder.Folders(loFolder.Name).Items
oContacts = oContacts.Restrict(strFilter)
For each loContact in oContacts
i=i+1
With loContact
Wait window .CompanyName
Endwith
Endfor
Endfor
? i
************

Is there a way that you see that I could combine the two steps into one?
L.A.Long
ProgRes
lalong1@charter.net
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform