When creating an Outlook Message how to apply Fonts and colours

Add-in Express™ Support Service
That's what is more important than anything else

When creating an Outlook Message how to apply Fonts and colours
 
mdriver


Guest


I am creating messages using Outlook11 model:

oMailitem = oOutlook.CreateItem(Outlook.OlItemType.olMailItem)
oMailitem.To = ToAddr
oMailitem.CC = ccAddr
oMailitem.BCC = bccAddr
oMailitem.Subject = subject
Item.HTMLBody = Replace(body, Chr(10), "<br>", 1, , CompareMethod.Text)
Posted 13 Jul, 2005 11:32:07 Top
mdriver


Guest


Opps hit space before I had finished. I will start again:

I am creating messages using Outlook11 model:

oMailitem = oOutlook.CreateItem(Outlook.OlItemType.olMailItem)
oMailitem.To = ToAddr
oMailitem.CC = ccAddr
oMailitem.BCC = bccAddr
oMailitem.Subject = subject
Item.HTMLBody = Replace(body, Chr(10), "<br>", 1, , CompareMethod.Text)
oMailitem.Save()
oMailitem.Display()

When the e-mail gets displayed the text in the body is created correctly but it has the outlook detault Times Roman 12pt formatting. The users have set customer font and colours for their e-mails which gets applied in Outlook when they click new e-mail.

Anybody know how to apply the the outlook new e-mail format settings to my e-mails that are created automatically in code.

thx

Matt
Posted 13 Jul, 2005 11:34:35 Top
Sergey Grischenko


Add-in Express team


Posts: 7187
Joined: 2004-07-05
Hi Matt.

I think you can use HTML tags to apply formatting for a new e-mail.
Just click on the "View Source" option in the context menu of Outlook inspector and you will see the HTML source of an e-mail (e-mail must be in HTML format). Use this HTML as an example to create your own HTML template.

Posted 14 Jul, 2005 06:13:03 Top