sending email

  • Thread starter Thread starter VJ
  • Start date Start date
V

VJ

I'm trying to send e-mail to two accounts...
and didn't know if this portion of the syntax was correct?


emailMsg.From = "(e-mail address removed);" + Session["Email"];
 
You mean To not From, right? and yes, they are semi-colon delimited. Not
sure if you can send from multiple accounts. In 2.0 this has changed to a
collection that accepts MailAddress objects.

Karl
 
MailMessage mail = new MailMessage( );

mail.To = "(e-mail address removed)" ;

mail.From = "(e-mail address removed)" ;

mail.Subject = "Hello" ;

mail.BodyFormat = MailFormat.Html ;

mail.Body = "<html><head></head><body>Hello</body></html>" ;

SmtpMail.Send( mail );
 
mail.To = "(e-mail address removed);[email protected]" ;
mail.From = "(e-mail address removed)" ;
mail.Subject = "Hello" ;
mail.BodyFormat = MailFormat.Html ;
mail.Body = "<html><head></head><body>Hello</body></html>" ;
SmtpMail.Send( mail );

--
-- Thom Little -- www.tlanet.net -- Thom Little Associates, Ltd.
--

Thom Little said:
MailMessage mail = new MailMessage( );

mail.To = "(e-mail address removed)" ;

mail.From = "(e-mail address removed)" ;

mail.Subject = "Hello" ;

mail.BodyFormat = MailFormat.Html ;

mail.Body = "<html><head></head><body>Hello</body></html>" ;

SmtpMail.Send( mail );


--
-- Thom Little -- www.tlanet.net -- Thom Little Associates, Ltd.
--

VJ said:
I'm trying to send e-mail to two accounts...
and didn't know if this portion of the syntax was correct?


emailMsg.From = "(e-mail address removed);" + Session["Email"];
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top