473,412 Members | 2,994 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,412 software developers and data experts.

HTML mail

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!

Nov 18 '05 #1
1 1572
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!

.

Nov 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Ian N | last post by:
Hi, I'm creating a site that posts orders to an email address when they're submitted, these orders need to be in the form of official invoices so i'm using HTML to format them. I already have...
0
by: James Hong | last post by:
Help please, I try to sending an email from my html page using the java applet. but it give error on most of the PC only very few work, what is the error i make the java applet show as below ...
8
by: LRW | last post by:
I'm not sure this message is totally appropriate for this group, so please, if anyone has a better group suggestion, let me know! My company sends out a monthly newsletter in HTML format to our...
3
by: T.Michelle | last post by:
We have few Mail templates (.html) which we use to send mails. We want to have some Logo in that ie ... when I send the mail to user the image should go as in-line embedded image in mail....
5
by: Thierry | last post by:
Hello. Is it possible to send an email with some HTML code ? I tried the following code, where $msg == '<html><body>... blah blab blah etc.</body></html>' : // Adresse de l'expediteur...
4
by: J Huntley Palmer | last post by:
How may I setup a proper HTML mail message with embedded href links using PHP, that follows all the MIME rules? Any examples or links would be appreciated. Thanks!
0
digicrowd
by: digicrowd | last post by:
http://bytes.com/images/howtos/applemail_sig_icon.jpg At first glance, it may not appear that Apple Mail (otherwise known as Mail.app) supports the use of HTML signature emails. However, with a...
10
by: happyse27 | last post by:
Hi All, I got this apache errors(see section A1 and A2 below) when I used a html(see section b below) to activate acctman.pl(see section c below). Section D below is part of the configuration...
2
by: anu b | last post by:
Now i am sending email to my friend using session variable... but my code is as below private bool SendEmail(string email) { try
3
by: anu b | last post by:
Hii I am using System.net.mail for sending email... i need to send a webpage with its html content as my email body .....for that i used mail.Isbodyhtml as true...but it is not working for me...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.