Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Combining message.BodyFormat = MailFormat.Html & message.BodyFormat = MailFormat.Text

Reply
Thread Tools

Combining message.BodyFormat = MailFormat.Html & message.BodyFormat = MailFormat.Text

 
 
=?Utf-8?B?bWc=?=
Guest
Posts: n/a
 
      02-08-2004
I'd like to send a single e-mail message message that uses the escape character \n as well as the html tag <i> in the body

How can I combine the two parts of this merssage

message.BodyFormat = MailFormat.Text
String msgTextA = "\n\nFrom: Carol Johnson\n\nSent: Monday, February 9, 2004

message.BodyFormat = MailFormat.Html
String msgTextB = "<i> Inventory Control <i>

????? message.Body = msgText; ??????

SmtpMail.Send(message);
 
Reply With Quote
 
 
 
 
Marshal Antony
Guest
Posts: n/a
 
      02-08-2004
Hi,
The System.Web.Mail part does not support sending more than one body
format for an email message.
You can use either MailFormat.Text or MailFormat.Html.
I think in your case if you just want to have line breaks,you can use
MailFormat.Html for your whole email body.
message.BodyFormat = MailFormat.Html;
String msgTextA = "<br><br>From: Carol Johnson<br><br>Sent: Monday,
February 9, 2004" ;// to convert to html way

Unfortunately the System.Web.Mail class does not allow you
to send an HTML message with support for non
HTML readers.
If you really want to support non HTML readers you will
need to look for some third party.
Here is a link :
http://www.quiksoft.com/newsletter/i...ult.asp?page=1
Hope this helps.
Regards,
Marshal Antony
..NET Developer
http://www.dotnetmarshal.com




"mg" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I'd like to send a single e-mail message message that uses the escape

character \n as well as the html tag <i> in the body.
>
> How can I combine the two parts of this merssage?
>
> message.BodyFormat = MailFormat.Text;
> String msgTextA = "\n\nFrom: Carol Johnson\n\nSent: Monday, February 9,

2004"
>
> message.BodyFormat = MailFormat.Html;
> String msgTextB = "<i> Inventory Control <i>"
>
> ????? message.Body = msgText; ??????
>
> SmtpMail.Send(message);



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Combining Profiles In Firefox? Freebird Firefox 7 06-23-2005 11:28 PM
Combining Messages Paul Firefox 1 01-12-2005 03:24 AM
T-bird and combining messages Dudhorse Firefox 2 11-12-2004 11:55 PM
Combining Newsgroup Messages tirebldr Firefox 4 10-31-2004 11:15 AM
Combining files zebra@cix.compulink.co.uk Firefox 3 07-29-2003 10:27 PM



Advertisments