Hi, I would like some help in outputting an HTML body to Outlook. I have the following code:
cMsgFile = "c:\backup\wel_let.txt"
cHtmlMsg1 = ""
nHandle = FOPEN(cMsgFile)
nSize=FSEEK(nHandle,0,2)
FSEEK(nHandle,0,0)
cHtmlMsg1 = FREAD(nHandle,nSize)
FCLOSE(nHandle)
oApp = createobject("outlook.application")
oMail = oApp.Createitem(0)
oMail.subject = "Welcome Letter"
oMail.to = "
abc9@hotmail.com"
oMail.htmlbody = cHtmlMsg1
oMail.send
oApp =.null.
This ouputs a blank body in my Outlook. If I were to replace:
oMail.htmlbody = cHtmlMsg1
with
oMail.body = cHtmlMsg1
I get all the HTML code instead of the format. What do I do so that I can get an HTML format in the body of my email.
Thanks,
Louis
PS When sending an email from VFP I get the following message in Outlook:
"A program is trying to automatically send e-mail on your behalf. Do you want to allow this?"
Is there a way to disable this feature?