Click here to Skip to main content
15,923,197 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Good After Noon to all,
I send a mail from my application. in body,i have to send like this,
"Dear All,
we have to do something for"
but 2 lines are concatenated.
"Dear All, we have to do something".

Any solution for this.

Thanks in Advance.
Posted
Updated 9-Jun-11 0:27am
v2
Comments
Monjurul Habib 9-Jun-11 6:24am    
share you code.

Depending on whether you send emails as text or HTML you need to either put a Environment.Newline ("\n") in the message, or a HTML newline "<br />"
string text = "Dear All,\nwe have to do...";

string text = "Dear All,<br />we have to do...";
 
Share this answer
 
Comments
[no name] 9-Jun-11 6:27am    
Well Said OriginalGriff.
Monjurul Habib 9-Jun-11 6:29am    
nice answer, my 5.
ajitha.pusapati 9-Jun-11 6:38am    
so nice.. Thanks..
for next line <br />.
for space ?.
Sergey Alexandrovich Kryukov 9-Jun-11 12:00pm    
My 5, mostly for Environment.Newline, which does not have to be "\n" and on Windows is "\r\n" :-).
--SA
Use Environment.Newline ("\n") in the message or Use <br /> tags if it is HTML.
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900