473,776 Members | 1,517 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problem With CDO in sending formatted text mail

In my ASP application,i need to send a formatted text mail (i.e with
newline characters).
here in my application i used a function in javascript which construts
the mail body
sample snippet

strbody=strbody +"dear customer,\n";
strbody=strbody +"we are glad to see ur response\n";
strbody=strbody +"we will make the needful thing as early as
possible\n";
............... ..
............... .......

sendmail(strbod y) \\ this is a function to send email that written in
vbscript
..............
............
then send mail function uses cdo to send mail.
inside th sendmail() function . i ve set the mail body as textbody

i.e
objCDO.To = strTo
objCDO.From = strFrom
objCDO.Subject = strSubject
objCDO.TextBody =strBody
objCDO.Send

The actual problem is it works fine and produces text line breaks in
yahoo , hotmail, gmail ids .but with some other ids ...i seems not
working properly..i doesnt respect the newline character and shows the
mailbody as a chunk of paragraph...

why this type of controdictory effect with cdo with some mail ids....
Give me an idea to get rid off this problem .. thanx in advance

visu.

Jun 14 '06 #1
4 6132

<k.******@gmail .com> wrote in message
news:11******** **************@ i40g2000cwc.goo glegroups.com.. .
In my ASP application,i need to send a formatted text mail (i.e with
newline characters).
here in my application i used a function in javascript which construts
the mail body
sample snippet

strbody=strbody +"dear customer,\n";
strbody=strbody +"we are glad to see ur response\n";
strbody=strbody +"we will make the needful thing as early as
possible\n";
............... .
............... ......

sendmail(strbod y) \\ this is a function to send email that written in
vbscript
.............
...........
then send mail function uses cdo to send mail.
inside th sendmail() function . i ve set the mail body as textbody

i.e
objCDO.To = strTo
objCDO.From = strFrom
objCDO.Subject = strSubject
objCDO.TextBody =strBody
objCDO.Send

The actual problem is it works fine and produces text line breaks in
yahoo , hotmail, gmail ids .but with some other ids ...i seems not
working properly..i doesnt respect the newline character and shows the
mailbody as a chunk of paragraph...

why this type of controdictory effect with cdo with some mail ids....
Give me an idea to get rid off this problem .. thanx in advance

visu.


Have you tried \r\n instead of just \n. I believe strictly speaking \r\n is
the standard in SMTP emails.

Jun 14 '06 #2
Anthony Jones wrote:

Have you tried \r\n instead of just \n. I believe strictly speaking \r\n is
the standard in SMTP emails.


thanks jones, the solution to above problem now in second position.
here now major problem is the send mail i send to some email ids not
reaches its destination , but for the mails to all free mailds like
yahoo,sify, hotmail, gmail,.....etc works fine and i could get my mail
at those mailbox.
i am unable to send mail to some specific ids.. while executing the
script there is no error message but the message not reaches its
destination.. i ve tried whole day by refreshing my mail box .
i am testing my application under windows 2003 iis 6 environment.is
there any specific SMTP server config is need?.. if so then how could i
able to send mail to free mail ids (yahoo, hotmail) alone?. not to some
specific ids.
can anyone help in this regard?....

Jun 14 '06 #3
then that is not an ASP related issue.. it is a mail server/ system admin
type of issue

once asp sends the email it has no control over what doesn't make it to the
sender, gets marked as spam, gets stopped by blacklist filters, etc etc
<k.******@gmail .com> wrote in message
news:11******** **************@ g10g2000cwb.goo glegroups.com.. .
Anthony Jones wrote:

Have you tried \r\n instead of just \n. I believe strictly speaking \r\n
is
the standard in SMTP emails.


thanks jones, the solution to above problem now in second position.
here now major problem is the send mail i send to some email ids not
reaches its destination , but for the mails to all free mailds like
yahoo,sify, hotmail, gmail,.....etc works fine and i could get my mail
at those mailbox.
i am unable to send mail to some specific ids.. while executing the
script there is no error message but the message not reaches its
destination.. i ve tried whole day by refreshing my mail box .
i am testing my application under windows 2003 iis 6 environment.is
there any specific SMTP server config is need?.. if so then how could i
able to send mail to free mail ids (yahoo, hotmail) alone?. not to some
specific ids.
can anyone help in this regard?....

Jun 14 '06 #4
Kyle Peterson wrote:
then that is not an ASP related issue.. it is a mail server/ system admin
type of issue

once asp sends the email it has no control over what doesn't make it to the
sender, gets marked as spam, gets stopped by blacklist filters, etc etc
<k.******@gmail .com> wrote in message
news:11******** **************@ g10g2000cwb.goo glegroups.com.. .


Still the problem pursues.. once again formatting comes in to big
issue..
First i ll tell my server Config
Win 2003
IIS 6 +SMTP server installed

I am using two functions
one in javascript which constructs the mail body
and another one in vbscript for sending mail by using CDO.

in javascript function i m constructing the mail body
like as follows..

strBody=strBody +"Dear customer \n";
strBody=strBody +"We got ur queries and we are working on them\n";
strBody=strBody +"You will get the response as early as possible \n";
...............
............... .
in the vbscript function

function sendmail(strBod y)
Set objMessage = CreateObject("C DO.Message")
objMessage.Subj ect = Request.Form("s ubject")
objMessage.Send er = Request.Form("F rom")
objMessage.To = Request.Form("T o")
objMessage.Text Body =strBody
objMessage.Send
end function

The problem is when i receive and read this mail at my official domain
ids(so******@vs nl.com) it looks not line breaked ..instead it looks
like chunk of paragraph.

But the surprising thing is the same mail sent to free mail ids is like
yahoo,hotmail, gmail are works fine.yes it looks line breaked.. why
this controversial effects is happening?...
whether my code is wrong or is there any problem with my smtp server
config (it s configed inside IIS itself. i could see a tree menu named
with smtp virtual server) . or the mail destination server problem.so
that it represent non line breaked mail. i couldnt predict cause for
this issue.

Give me idea to solve this problem. thanks in advance.thanks for
previous replys too

visu

Jun 16 '06 #5

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

Similar topics

14
9079
by: Christophe Cerbourg | last post by:
hi, Bonjour, I'm using PHPMailer class to send mails and it works fine for HTML ones. But I can't manage to send correctly a text formatted mail... I tried this : - $message = "first line*\n*second line"; - $message = "first line*\r\n*second line"; - $message = "first line*".chr(13).chr(10)*second line";
1
1711
by: Simon Wigzell | last post by:
I'm generating HTML formatted emails in my asp program using CDONT. Depending on hoow ling the link is it will sometimes wrap and ruin the link. The is Detail email properties listing : ------=_NextPart_000_0314_01C418C2.90C5F130 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit At your request, we have created a webpage message for you: here...
4
2973
by: Francois Keyeux | last post by:
hello everyone: i have a web site built using vbasic active server scripting running on iis (it works on either iis 50 and 60, but is designed for iis 50) i know how to create a plain text email by creating a text file, with content following certain format, and saving that file into the correct '..\mailroot\pickup' folder, and it is working fine
5
2636
by: BaWork | last post by:
I have a web form where a client can select which site members to send an email to. This form is populated from the contents of the member table, so the form can have 0-x names listed on it depending on member expiration dates. When the form is submitted, the code loops through the form contents and sends an email to those members that meet the selected criteria. All this worked perfectly when I was sending text emails, but since I
2
1750
by: Paul Turley | last post by:
Does anyone have some sample code for sending an HTML formatted message using CDONTS? Thanks RE: Sending HTML formatted mail using CDONTS -- Paul Turley, MCSD, MCAD, MCT, MSF Practitioner, A+ Technician
3
2227
by: VB Programmer | last post by:
My company has it's own webserver, which is going to host our ASP.NET web application. We want the website to be able to send out emails. 1. What do I need on the server so that it has the abillity to send out emails? It is a Windows 2000 Professional SP3 server. 2. Any examples (code, etc...) on how to send out emails via an ASP.NET webform? Thanks!
1
2945
by: robbiesmith79 | last post by:
Just so this is out there on the web, I battled the past 24 hours about this. Background info... I developed a ecommerce website in PHP 4 on a shared linux hosting plan from GoDaddy and had the html formatted emails sending as text/html and were going fine with limited header information. Then we moved the site over to a Dedicated Linux hosting plan. This time, it's PHP 5. Things are bound to not work as expected moving to a new...
4
5068
by: cybervigilante | last post by:
I sent HTML formatted email, using PHP, to my Yahoo address from my server, and it came out fine, styles and all. I sent it to my gmail address to test it and all I see is the raw html code. But I do get formatted email in gmail, so I know people make it work somehow. I'm looking right at a gmail message that I copied to Dreamweaver and it's using Strong and Red text attributes that work in gmail. But mine don't. What do you do...
8
1095
by: wengkit | last post by:
i'm using System.Web.Mail in my application and i set the BodyFormat = MailFormat.Html; in MS C#.net MailMessage mailMsg = new MailMessage(); mailMsg.To = txtTo.Text; mailMsg.Cc =txtCc.Text; mailMsg.Bcc = txtBcc.Text; mailMsg.Subject = txtSubject.Text; mailMsg.BodyFormat = MailFormat.Html;
0
9627
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10287
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10060
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9922
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8951
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7469
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6721
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
2
3621
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2859
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.