jmail问题 简单 答对50分
安装了jmail4.3 直接在工程里引用了jmail.dll文件(我用的是vs2003(c#))
想用他来给163邮箱的用户发送确认邮件 我的代码如下:
private void Button1_Click(object sender, System.EventArgs e)
{
jmail.Message Jmail=new jmail.MessageClass();
String Subject="heshuai";
String body="my first email!";
String FromEmail="hesai1234@163.com";
String ToEmail="posden@163.com";
Jmail.Silent=false;
Jmail.Logging=true;
Jmail.Charset="GB2312";
Jmail.ContentType="text/html";
Jmail.AddRecipient(ToEmail,"","");
Jmail.From=FromEmail;
Jmail.MailServerUserName="hesai1234" ;
Jmail.MailServerPassWord="*****" ;
Jmail.ReplyTo="hesai1234@163.com";
Jmail.Subject=Subject;
Jmail.Body=body;
Jmail.Send("smtp.163.com",false);
Jmail.Close() ;
Response.Write("this is my first email!");
}
发送失败 原因是The message was undeliverable. All servers failed to receive the message
如何解决?帮忙 答对马上给分