Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Problem With CDO in sending formatted text mail

Reply
Thread Tools

Problem With CDO in sending formatted text mail

 
 
k.visube@gmail.com
Guest
Posts: n/a
 
      06-14-2006
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(strbody) \\ 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.

 
Reply With Quote
 
 
 
 
Anthony Jones
Guest
Posts: n/a
 
      06-14-2006

<> wrote in message
news: oups.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(strbody) \\ 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.



 
Reply With Quote
 
 
 
 
k.visube@gmail.com
Guest
Posts: n/a
 
      06-14-2006
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?....

 
Reply With Quote
 
Kyle Peterson
Guest
Posts: n/a
 
      06-14-2006
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


<> wrote in message
news: oups.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?....
>



 
Reply With Quote
 
k.visube@gmail.com
Guest
Posts: n/a
 
      06-16-2006
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
>
>
> <> wrote in message
> news: oups.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(strBody)
Set objMessage = CreateObject("CDO.Message")
objMessage.Subject = Request.Form("subject")
objMessage.Sender = Request.Form("From")
objMessage.To = Request.Form("To")
objMessage.TextBody =strBody
objMessage.Send
end function

The problem is when i receive and read this mail at my official domain
ids() 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

 
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
pls help me when i sent mail, it vil sending twice instead of once ,am using java.mail,am sending my code.... shailajabtech@gmail.com Java 0 09-28-2006 06:38 AM
CDO Mail sending error =?Utf-8?B?SWJyYWhpbS4=?= ASP .Net 3 07-26-2006 12:41 PM
Sending Mail using CDO Kurien Baker Fenn ASP General 4 07-21-2005 01:47 AM
Sending HTML formatted mail using CDONTS Paul Turley ASP .Net 2 08-12-2003 09:16 AM
Sending Mail without CDO or JMail Ron ASP .Net 2 06-30-2003 10:13 PM



Advertisments