sending HTML mail

mfstuart mfstuart at
Fri Apr 24 19:38:21 EDT 2009

Hi Sadhu,
If you are on Windows, here's a VBScript that allows HTML body content:

Dim objOutl
Dim strHTML
Set objOutl = CreateObject("Outlook.Application")
Set objMailItem = objOutl.CreateItem(olMailItem)

strHTML = "<HTML>"
strHTML = strHTML & "<HEAD>"
strHTML = strHTML & "<BODY>"
strHTML = strHTML & "NEW MESSAGE</br>"
strHTML = strHTML & "<hr>"
strHTML = strHTML & "This is a test message"
strHTML = strHTML & "</BODY>"
strHTML = strHTML & "</HTML>"

'comment the next line if you do not want to see the outlook window
strEmailAddr  = "me at"
objMailItem.Recipients.Add strEmailAddr
objMailItem.Subject = "Hi"
objMailItem.HTMLBody = strHTML
'objMailItem.Attachments.Add "file.xml"
Set objMailItem = nothing
Set objOutl = nothing

HTH you,
Mark Stuart

Sadhu Nadesan wrote:
> Sarah, Mikey, or anyone?
> Say, I know this question gets asked a lot.  I have been searching the 
> mailing list, downloading stacks, etc., but haven't found the exact 
> answer so pardon me for asking it again!  The closest thing was Mikey's 
> post. (below)
> The question is, how to send an HTML email message.  Or rather, a nicely 
> formatted message. Same thing I guess.   I think the revMail command is 
> awesome, but, the plain text message body looks kinda ugly for the 
> message I have in mind, and, although I could write a CGI script and 
> work out all the plumbing (actually I have done this before, a la 
> Sivakatirswami), I'd rather find a stack like Sarah's that is already 
> done and talks directly to the mail server without the CGI piece.  Am I 
> lazy, well, ,maybe so, I just don't want to reinvent the wheel when it's 
> been done. Plug and go!  I have enough plumbing to create as it is.
> I am pretty hopeful someone has modified Sarah's stack or has something 
> ready to go that will send HTML mail and can be grafted onto one's rev 
> app.  Yes??  Are you willing to share, whoever you are?  Fingers 
> crossed, and, Mahalo!
> Sadhu
> ps, the post below was good but refers to stuff I didn't find yet, eg,  
> "as previously suggested' etc.  I can keep looking though.
>> From: Mikey <mikeythek at ... 
>> <>>
>> Subject: Re: HTML SMTP Library 
>> <>
>> Newsgroups: gmane.comp.ide.revolution.user 
>> <>
>> Date: 2008-09-03 00:45:52 GMT (33 weeks, 2 days, 18 hours and 21 
>> minutes ago)
>> I've got other things that I have to do tonight, so I can't give you
>> the complete cookbook, but here is the outline.
>> 1) Download one of the following stacks:
>>      a)
>>      b)*SMTP**library*.rev.gz
>> <>
>> 2) After looking through the *SMTP* *Library* Demo (the second one), and
>> clicking on the *Library* button, I got into Sarah's *SMTP* *library*. 
>> I'm
>> sure this works just as well with the other, but as I said, I've got
>> other pressing things to do tonight.  However, you should be able to
>> figure it out after this.
>> 3) Search for "Content-Type".  Change it as I've previously suggested.
>> 4) Follow my formatting suggestions for the body.
>> 5) Send *HTML*-formatted emails without having to embed the *HTML* in an
>> attachment.
> _______________________________________________
> use-revolution mailing list
> use-revolution at
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:

View this message in context:
Sent from the Revolution - User mailing list archive at

More information about the use-livecode mailing list