myMailMsg.Body = "Please call StarLan to chen Database Server";
myMailMsg.BodyFormat = MailFormat.Text;
SmtpMail.SmtpServer="localhost";
SmtpMail.Send(myMailMsg);
本来是用外部的SMTP SERVER
SmtpMail.SmtpServer="smtp.XXX.com";
但后来发现由于DATA CENTER的FIREWALL原因,改用
SmtpMail.SmtpServer="localhost";
运行后系统提示错误信息:
Email Fail Could not Access ''CDO.Message'' object. Here is the full error message output: System.Web.HttpException: Could not access ''CDO.Message'' object. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x8004020F): The server rejected one or more recipient addresses. The server response was: 550 5.7.1 Unable to relay for 12321323@mobile.att.net