944,117 Members | Top Members by Rank

Ad:
  • ASP.NET Discussion Thread
  • Unsolved
  • Views: 5297
  • ASP.NET RSS
Sep 8th, 2005
0

How to compose an html complex email?

Expand Post »
Does anybody know how to embed a web page in an email body? What softwares are needed? Thanks!! :rolleyes:
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
springcity is offline Offline
1 posts
since Sep 2005
Oct 26th, 2005
0

Re: How to compose an html complex email?

hey,

if you are sending emails using ASP.NET, then you need not worry about anything extra..just use the System.Web.Mail namespace, every setting is present there..for example look at this code below:

string MailServer=""; //Your mail server name
System.Web.Mail.MailMessage SendMail = new System.Web.Mail.MailMessage(); //create a new mail message SendMail.BodyEncoding=System.Text.Encoding.UTF8; //set encoding
SendMail.BodyFormat=System.Web.Mail.MailFormat.Html; //set Format..There are HTML and Text formats available
SendMail.To=mailTo; //to
SendMail.From=mailFrom; //from
SendMail.Subject=subject;//subject

SendMail.Body=mailBody; //mail Body..The complete HTML string of page
SendMail.Cc = mailCC;//CC
SendMail.Bcc = mailBCC;//BCC
System.Web.Mail.SmtpMail.SmtpServer=MailServer;//set mail server
System.Web.Mail.SmtpMail.Send(SendMail); //send email

Hope this helps
Reputation Points: 10
Solved Threads: 0
Newbie Poster
v_ashwani is offline Offline
5 posts
since Oct 2005

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in ASP.NET Forum Timeline: Help with Roles Stored in SQL database
Next Thread in ASP.NET Forum Timeline: Specify row/columns when export to Excel from DataGrid?





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC