Link to home
Start Free TrialLog in
Avatar of xinkun
xinkun

asked on

SMTP error (code 0xC00402C7), multiple receivers email being dumped to badmail folder

A SMTP problem: when email receiver is more than one person which are saprated by ";", the smtp will dump the mail to badmail folder with no reason. But ok for one email address. "The specific error code was 0xC00402C7" in BDR file and "Delivery to the following recipients failed.
someone1@somecom.com; someone2@someothercom.com" in BAD file

P.S both email addresses are valid, and can be sent if one receiver.

Many thanks
Avatar of n0ch1ps
n0ch1ps
Flag of United Kingdom of Great Britain and Northern Ireland image

Try it this way :

objMail.To = "someone1@someone.com";
objMail.To = "someone2@someone.com";
objMail.To = "someone3@someone.com";

Regards

Si
ASKER CERTIFIED SOLUTION
Avatar of daniel_c
daniel_c

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
You can't pass the address as a string like that, you must first call the object, i.e. Set ObjMail = Server.CreateObject("CDONTS.NewMail") in each instance.

The address is seen by the smtp server as someone1@somecom.com,someone2@someothercom.com.

Cheers

Si
Avatar of xinkun
xinkun

ASKER

Thanks, daniel c
It works when changed to "," from ";". But very strange since according to MSDN, Multiple recipients on the list are separated by semicolons
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cdo/html/_denali_to_property_cdonts_newmail_object_.asp
I stand corrected, I've never got it to work that way :-\

Thanks

Si