How to set up HTML in Body of Outlook programmatically.

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?
 
S

Stefan Hoffmann

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 <--
 
D

Daniel Pineault

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.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top