CDO problem in ASP

i have a problem when i send mail from my asp page with the text i write in body message. In my page i have a textarea where the user can write text. When i receive the mail i see that all the carriage return have been deleted and the text is all attacched and If i cut and paste html formatted text in the textarea object and then send the message i receive only a part of the html text.

What i have to do to send mail in the same format i wrote. If i can in html formatted text is good, but i can also use simpe, text but i can't loose my cr at the end of the paragraphs.

Thanks.
 
Can you post your code here for some review?
Not all of it just the mail code section is fine :)
 
The code is this

Dim iMsg, iConf, Flds

Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
Flds("http://schemas.microsoft.com/cdo/configuration/urlgetlatestversion") = True

With iMsg

'Assegnazione delle configurazioni
Set .Configuration = iConf

.From = Request.QueryString("cMit")
.To = Request.QueryString("cDes")
.Subject = Request.QueryString("cOgg")

'.HTMLBody = Request.QueryString("cMes")
'.TextBody = Request.QueryString("cMes")

'Invio di una pagina web
'.CreateMHTMLBody "url"
'Invio con allegato
'.AddAttachment server.mappath("file")

'Invia l'email
.Send()

end with

set Flds = Nothing
set iConf = Nothing
set iMsg = Nothing

I call this ASP from another ASP page where i have the textarea with the message body and i pass it to the mail.asp with other parameters .

Thanks
 
I don't believe this is a cdo or mail problem. Have you tried to write the text to the page using:
response.write Request.QueryString("cMes")
This is a good way to dedug in asp.
There is not much you can do about this. You need to insert a carrage return and line feed in your text where you need a new line like this: Chr(13) & Chr(10)

The other and best solution is to use a text editor instead of a text area control. Fckeditor is one but for your use over kill, its free.

Joe
 
Back
Top