Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > HTML mail

Reply
Thread Tools

HTML mail

 
 
=?Utf-8?B?U2pvZXJ0IEViYmVu?=
Guest
Posts: n/a
 
      08-06-2004
I hope this is the right forum to ask the following question:

Using CDOSYS to send HTML mail and getting exclamation
mark ! at or after every 991st character. The application
worked fine on Windows 2000 but gives this problematic
behavior on Windows 2003. There is a solution for ASP
(set encoding to "quoted-printable") but we cannot seem
to find anything for .Net (C#).

Any suggestions would be appreciated!

 
Reply With Quote
 
 
 
 
Charles Chen
Guest
Posts: n/a
 
      08-06-2004
You can use CDOSYS from within ASP.Net by including the
CDOSYS dll file in your solution. CDOSYS provides much
more functionality than the .Net mail object.

Give it a shot. You would pretty much use it the same way
that you use CDOSYS from ASP. Very easy.

Sample CDOSYS usage (not for standard mail):
CDO.Message cdoMessage
= new CDO.MessageClass();

ADODB.Stream adoStream
= null;
CDO.ConfigurationClass cdoConfig
= new CDO.ConfigurationClass();

cdoConfig.Fields
[CdoConfiguration.cdoHTTPCookies].Value =
MakeCookieString(cookies);
cdoConfig.Fields
[CdoConfiguration.cdoURLGetLatestVersion].Value = true;
cdoConfig.Fields.Update();

try{
cdoMessage.MimeFormatted
= true;

cdoMessage.AutoGenerateTextBody = false;
cdoMessage.Configuration
= cdoConfig;
cdoMessage.CreateMHTMLBody
(url, CDO.CdoMHTMLFlags.cdoSuppressNone, "", "");

cdoMessage.BodyPart.Charset
= "utf-8";

cdoMessage.BodyPart.BodyParts
[1].ContentTransferEncoding = "quoted-printable";

adoStream
= cdoMessage.GetStream();
adoStream.Charset
= "utf-8";
adoStream.LineSeparator =
ADODB.LineSeparatorEnum.adLF;
}
catch(Exception ex){
throw new Exception
(String.Format
(_errorString, "MailUtilities.MhtmlGenerator.GetDataStream"
, ex.Message));
}
finally{
cdoMessage = null;
}

return adoStream;

>-----Original Message-----
>I hope this is the right forum to ask the following

question:
>
>Using CDOSYS to send HTML mail and getting exclamation
>mark ! at or after every 991st character. The application
>worked fine on Windows 2000 but gives this problematic
>behavior on Windows 2003. There is a solution for ASP
>(set encoding to "quoted-printable") but we cannot seem
>to find anything for .Net (C#).
>
>Any suggestions would be appreciated!
>
>.
>

 
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 Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Clean way to send HTML e-mail with image using default mail client? Ramon Java 2 10-25-2007 02:02 AM
AOL MAIL HTML ProfilerCA@aol.com Computer Information 1 12-28-2006 01:31 PM
Problem with System.Web.Mail.MailMessage and HTML mail =?Utf-8?B?TWlja2VCb3k=?= ASP .Net 1 06-21-2005 06:11 AM
How to send an html message with inline images and text for non html mail clients? John Sutter ASP .Net 0 01-13-2004 07:08 PM
HTML E-Mail with HTML Form ??? Glen ASP .Net 1 11-13-2003 05:26 PM



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57