-
October 8th, 2011, 11:04 AM
#1
how to send bulk mail?
Hai all,
I want to send bulk mail in asp.net using C#...Front End:Asp.Net with C# and Back End:Sql Server.
Following code is used to sending from gmail only...how i send from yahoo,hotmail,rediffmail,etc...
MailMessage mm = new MailMessage();
mm.From =new MailAddress(FromTextBox.Text);
mm.To.Add(ToTextBox.Text);
if (FileUpload1.HasFile)
{
Attachment at = new Attachment(FileUpload1.PostedFile.FileName);
mm.Attachments.Add(at);
}
mm.Subject = SubjectTextBox.Text;
mm.Body = MessageTextBox.Text;
SmtpClient sc = new SmtpClient();
sc.Host ="smtp.gmail.com";
sc.Port = 587;
sc.EnableSsl = true;
sc.Credentials =new System.Net.NetworkCredential(FromTextBox.Text,PasswordTextBox.Text);
sc.Send(mm);
Response.Write("Mail Sended");
how to send bulkmail from gmail,yahoo,rediffmail,hotmail etc..
how to attached single and multiple files and images...
how to store sended mail with and without single and multiple attachments...
how to do these all...please any body send code...
thanks in advance...
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|