Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Sending an email after i push the save button from a cla
Message
 
To
17/01/2003 10:24:43
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00742877
Message ID:
00743013
Views:
17
If you want to automate outlook in order to send mail, here is some sample code for you:
#DEFINE olFolderInbox 6 
loOutlook = CREATEOBJECT("Outlook.application")
loNameSpace =loOutlook.GetNamespace("MAPI")
loInbox = loNameSpace.GetDefaultFolder(olFolderInbox)
loMail = loInbox.Items.ADD()
lcErr = ON("ERROR")
lcEmailAddress = "g@thescapins.com"
lcSubject = "Test Subject"
lcBody = "This is the test body"
ON ERROR ** && Ignore Outlook errors
loMail.Recipients.ADD(lcEmailAddress)
ON ERROR &lcErr

loMail.Subject = lcSubject
loMail.Body = lcBody
loMail.DISPLAY
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform