How do I specify multiple recipients? To specify multiple recipients for a MailMessage, simply separate each recipient with a semicolon. For example:
mail.To = "me@mycompany.com;him@hiscompany.com;her@hercompany.com";
MailMessage mail = new MailMessage(); mail.To = "me@mycompany.com;him@hiscompany.com;her@hercompany.com"; mail.From = "you@yourcompany.com"; mail.Subject = "this is a test email."; mail.Body = "this is my test email body."; SmtpMail.SmtpServer = "localhost"; //your real server goes here SmtpMail.Send( mail );
Dim mail As New MailMessage() mail.To = "me@mycompany.com;him@hiscompany.com;her@hercompany.com" mail.From = "you@yourcompany.com" mail.Subject = "this is a test email." mail.Body = "this is my test email body." SmtpMail.SmtpServer = "localhost" 'your real server goes here SmtpMail.Send(mail)
Copyright © 2004 Contact: Dave Wanta. aspNetEmail aspNetPOP3 aspNetMime