|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
System.Net.Mail.MailAddress.ToIn the old System.Web.Mail, you could use a string of delimited email address
(say stored in a config file) and bulk email setting it to the TO property. eg "pers***@whereever.com,pers***@whereever.com" The new System.Net.Mail.MailAddress.To appears to allow the string ok (we are on Lotus so uses , instead of ; for multiple email addresses) but appears to only send to the first email address and ignore the rest and no error message. I don't seriously have to instantiate a copy of MailMessage to send to multiple recipients do I. Am I doing something wrong or is it a Lotus or email thing.. just goes through smtp doesn't it... Could it be a mail server setting as it only appears to allow internal deliveries. Any help much appreciated.. Thanks -- Kind Regards Amelia Check out the following web site, devoted to the System.Net.Mail namespace:
http://www.systemnetmail.com/ It has the information you're looking for, as well as just about anything else pertaining to sending email with the System.Net.Mail namespace. -- Show quoteHTH, Kevin Spencer Microsoft MVP Short Order Coder http://unclechutney.blogspot.com The devil is in the yada yada yada "Amelia" <Ame***@discussions.microsoft.com> wrote in message news:FE02A475-D54F-4606-9E3C-0ED499E783CF@microsoft.com... > In the old System.Web.Mail, you could use a string of delimited email > address > (say stored in a config file) and bulk email setting it to the TO > property. > eg "pers***@whereever.com,pers***@whereever.com" > > The new System.Net.Mail.MailAddress.To appears to allow the string ok (we > are on Lotus so uses , instead of ; for multiple email addresses) but > appears > to only send to the first email address and ignore the rest and no error > message. I don't seriously have to instantiate a copy of MailMessage to > send > to multiple recipients do I. Am I doing something wrong or is it a Lotus > or > email thing.. just goes through smtp doesn't it... Could it be a mail > server > setting as it only appears to allow internal deliveries. Any help much > appreciated.. Thanks > -- > Kind Regards > Amelia Thanks Kevin. I checked that site and it was useful.
Bad news is that the To property IS a collection so will ahve to pick up my string, tokenise it and then loop and add each recipient into the collection... Seems like a backward step to me from the old class though. Cheers -- Show quoteKind Regards Amelia "Kevin Spencer" wrote: > Check out the following web site, devoted to the System.Net.Mail namespace: > > http://www.systemnetmail.com/ > > It has the information you're looking for, as well as just about anything > else pertaining to sending email with the System.Net.Mail namespace. > > -- > HTH, > > Kevin Spencer > Microsoft MVP > Short Order Coder > http://unclechutney.blogspot.com > > The devil is in the yada yada yada > > > "Amelia" <Ame***@discussions.microsoft.com> wrote in message > news:FE02A475-D54F-4606-9E3C-0ED499E783CF@microsoft.com... > > In the old System.Web.Mail, you could use a string of delimited email > > address > > (say stored in a config file) and bulk email setting it to the TO > > property. > > eg "pers***@whereever.com,pers***@whereever.com" > > > > The new System.Net.Mail.MailAddress.To appears to allow the string ok (we > > are on Lotus so uses , instead of ; for multiple email addresses) but > > appears > > to only send to the first email address and ignore the rest and no error > > message. I don't seriously have to instantiate a copy of MailMessage to > > send > > to multiple recipients do I. Am I doing something wrong or is it a Lotus > > or > > email thing.. just goes through smtp doesn't it... Could it be a mail > > server > > setting as it only appears to allow internal deliveries. Any help much > > appreciated.. Thanks > > -- > > Kind Regards > > Amelia > > > |
|||||||||||||||||||||||