Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Back to VFP, so Outlook OLE hints requested
Message
 
 
À
20/07/2000 10:25:48
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00393971
Message ID:
00394987
Vues:
11
Thanks to everyone how helped on this, with the provided hints, and much searching of technet and MSDN, the solution follows:
* Folder Name Value *
* ---------------------- *
* Deleted Items 3 *
* Outbox 4 *
* Sent Items 5 *
* Inbox 6 *
* Calendar 9 *
* Contacts 10 *
* Journal 11 *
* Notes 12 *
* Tasks 13 *
* *
****************************************************************
#DEFINE CRLF CHR(13)+CHR(10)
#DEFINE TABC CHR(9)
SET OLEOBJECT ON

Local lto, lsubject, lbody && strings

&& These will come from db later today
lto = "Gottschewski LA@Comox" && Just got volenteers for further testing
lsubject = "Test"
lbody = "Yadda "
lbody = lbody + lbody

oMailOle = CREATEOBJECT("Outlook.Application")
NSOle = oMailOle.GetNamespace("MAPI")
oOutFolder = NSOle.GetDefaultFolder(4) && constant for outbox

oMailItem = oOutFolder.Items.Add()
with oMailItem
.To = lto
.Body = lbody
.Subject = lsubject
.save && This one lousy line is ESSENTIAL, or it won't work
.Send
endwith
Release oMailItem
Release NS0le
Release oMailOle
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform