FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for CA-Clipper To send email with image
Posts: 49
Joined: Thu Dec 22, 2005 12:50 PM
To send email with image
Posted: Wed Aug 09, 2006 12:35 PM

it has as to below insert image in the sending of email in the example?

include "fivewin.ch"


FUNCTION SendMail


LOCAL oOutLook,oMailItem,oRecip,oAttach

oOutLook := TOleAuto():New("Outlook.Application")

oMailItem := oOutLook:Invoke("CreateItem", 0)

oRecip := oMailItem:Invoke("Recipients")
oRecip:Invoke("Add", "lara.softhouse@gmail.com")
oRecip:Invoke("Add", "cleiton.softhouse@bol.com.br")

oMailItem:Set("Subject", "Testing e-mail via ole fw")

oMailItem:Set("Body", "Assunto, referente fatura 0001 no valor de "+CRLF+ ;
"R$ 1.500,00"+CRLF+CRLF+"Tudo Informática"+CRLF)

oAttach := oMailItem:Invoke("Attachments")
oAttach:Invoke("Add", "c:\autoexec.bat")
oAttach:Invoke("Add", "c:\config.sys")

oMailItem:Invoke("Send")

oRecip:End()
oAttach:End()
oMailItem:End()
oOutLook:End()

MsgInfo("Mensagem enviado com sucesso !")

RETURN NIL

Kleyton

Fwh906

Brazil
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
To send email with image
Posted: Thu Aug 10, 2006 05:28 PM
Kleyton,
oMailItem:Set( "HTMLBody", '<HTML><HEAD></HEAD><BODY><img src="http://www.fivetechsoft.com/images/logo5t2.gif"</BODY></HTML>' )
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 49
Joined: Thu Dec 22, 2005 12:50 PM
To send email with image
Posted: Fri Aug 11, 2006 11:25 AM

Antonio Linares, Debtor for the aid, but did not give certain, did not insert the image in the body of the email.

He has as to use this process of sending of email for the OutlookExpress?

Kleyton

Fwh906

Brazil
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
To send email with image
Posted: Sat Aug 12, 2006 05:48 AM

Kleyton,

You cannot use OLE with Outlook Express, but you can use FW's TMail class. See my reponse to your message in the FWH section.

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
To send email with image
Posted: Sat Aug 12, 2006 06:42 AM

Kleyton,

Here it works fine with Outlook 2003 (not Outlook Express).

regards, saludos

Antonio Linares
www.fivetechsoft.com

Continue the discussion