Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Help with sending Outlook email in VFP
Message
De
27/06/2003 12:23:35
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00804758
Message ID:
00804762
Vues:
28
Try this code
oOUTLOOK= Createobject('outlook.application')
omail=oOUTLOOK.createitem(0)
omail.recipients.add("xxxx@xxxx.com")
oRecipient.type = 3
*omail.recipients.Add(lcEmaillist)
omail.Display
Release  omail
oOUTLOOK = .Null.
Release oOUTLOOK

*oRecipients types
*1 = to
*2 = cc
*3 = bcc
>I have some sample code from a book on sending email from VFP using Outlook, which is below:
>
>Set proc to officapi (this is a bunch of lines of code I will not post unless needed)
>
>public oOutlook
>oOutlook = CreateObject("cusOutlookAutomation")
>oOutlook.show()
>oOutlook.New
>oOutlook.SetTo("yourname@domain.net")
>oOutlook.SetSubject("Test Message Subject")
>oOutlook.SetBody("This is body text")
>oOutlook.AddAttachment("c:\demo.txt")
>oOutlook.send
>
>
>The help I need is I simply want my app to have the user select email addresses that the email goes to (from my table) and then simply open an Outlook email with them in it BUT NOT SEND IT IMMEDIATELY. I want the user to then add their attachments and body of the message in Outlook so they can use Outlook's spell check and other features that they are custom to and want. When they are done they will click on Outlook’s “Send” button.
>
>Any suggestions would be appreciated.
>
>Regards,
>Torrey
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform