深
深圳小吴
Unregistered / Unconfirmed
GUEST, unregistred user!
NMSMTP1->Host ="smtp.szonline.net";
NMSMTP1->Port =25;
NMSMTP1->UserID ="netchong";
NMSMTP1->Connect();
if(NMSMTP1->Connected){
NMSMTP1->SubType = mtPlain;
// NMSMTP1->EncodeType = uuMime;
NMSMTP1->EncodeType = uuCode;
NMSMTP1->PostMessage->FromAddress = "dkfjksd"; //发信地址
NMSMTP1->PostMessage->FromName ="dkfj" ; //发信人
NMSMTP1->PostMessage->Subject = "Edit4.Text"; //主题
NMSMTP1->PostMessage->Date = "1999";
NMSMTP1->PostMessage->ToAddress->Text="wjmfzsz@etang.com"; //收信地址
// NMSMTP1.PostMessage.Attachments.AddStrings(Listbox1.Items); //附件
NMSMTP1->PostMessage->Body->Text="djfkjasdfjk";
NMSMTP1->SendMail();
NMSMTP1->Disconnect();
代码如上:
但在执行NMSMTP1->SendMail();总是有个错误:503 error:need RCPT command!
为什么会这样?
NMSMTP1->Port =25;
NMSMTP1->UserID ="netchong";
NMSMTP1->Connect();
if(NMSMTP1->Connected){
NMSMTP1->SubType = mtPlain;
// NMSMTP1->EncodeType = uuMime;
NMSMTP1->EncodeType = uuCode;
NMSMTP1->PostMessage->FromAddress = "dkfjksd"; //发信地址
NMSMTP1->PostMessage->FromName ="dkfj" ; //发信人
NMSMTP1->PostMessage->Subject = "Edit4.Text"; //主题
NMSMTP1->PostMessage->Date = "1999";
NMSMTP1->PostMessage->ToAddress->Text="wjmfzsz@etang.com"; //收信地址
// NMSMTP1.PostMessage.Attachments.AddStrings(Listbox1.Items); //附件
NMSMTP1->PostMessage->Body->Text="djfkjasdfjk";
NMSMTP1->SendMail();
NMSMTP1->Disconnect();
代码如上:
但在执行NMSMTP1->SendMail();总是有个错误:503 error:need RCPT command!
为什么会这样?