How can I insert HTML code into Outlook.ContactItem.Body?

C

chill

Gretings,

the problem is that ContactItem.Body is plain text property.
I'd like to do this in C#.
Could somebody help wityh this issue?
Thanks.
 
C

chill

Thanks for reply.

Ok, so how can I insert HTML link in body if it is rich-text?
In Outlook 2003 ContactItem body I can insert different objects, some of
them are stored as attachments. However I do not have idea how I can e.g.
format text in body.
I try someth like this:

/************************************/
....
ContactItem contact = applicationObject.CreateItem(...);
...
contact.Body = "<b>Text should be bold in body</b>";
...
....
/************************************/
 
S

Sue Mosher [MVP-Outlook]

Outlook should automatically detect the http:// in the text and format it as
a clickable link.

To insert formatted text into an RTF item, you'd need to use either CDO 1.21
with a helper .dll or Redemption. See
http://www.outlookcode.com/d/formatmsg.htm Since both methods require
installation of an additional component, I'd go with Redemptin for ease of
use and additional features. CDO also is not officially supported in .NET
languages, although I know people use it anyway.
--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 

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