How to set up HTML in Body of Outlook programmatically.

  • Thread starter Thread starter ThomasAJ
  • Start date Start date
T

ThomasAJ

I can send vanilla text in the body of an Outlook message but I have no idea
how to construct a HTML message with pictures.

Any ideas?
 
hi Thomas,
I can send vanilla text in the body of an Outlook message but I have no idea
how to construct a HTML message with pictures.
You have to create the HTML "manually" with or without embedded images.
This HTML needs to be assigned to .HTMLBody. Use early binding and the
Object Browser to explore the Outlook DOM in the VBA editor.



mfG
--> stefan <--
 
Stefan is correct. Also take a look at the following link as it demonstrates
the synthax (ie: .HTMLBody = "<HTML><BODY>Enter the message text here.
</BODY></HTML>").

http://msdn.microsoft.com/en-us/library/aa171418(office.11).aspx

You need to code your message as if you were creating a HTML document, all
the standard tag apply (<i></i>, <b></b>, <br/>, <p>, <h1>,..., <h6>, <a
href>..., <img src>...., ...). Make sure you use opening and closing <HTML>
and <BODY> tags.
--
Hope this helps,

Daniel Pineault
For Access Tips and Examples: http://www.cardaconsultants.com/en/msaccess.php
If this post was helpful, please rate it by using the vote buttons.
 
Back
Top