procedure TForm1.recieveClick(Sender: TObject);//收信
begin
try
nmpop31.getmailmessage(listbox1.itemindex+1);
except
showmessage('无法收信');
end;
Edit8.Text := NMPOP31.MailMessage.From;
Edit5.Text := NMPOP31.MailMessage.Subject;
Edit9.Text := Copy(NMPOP31.MailMessage.MessageID,2,4)+'/'+Copy(NMPOP31.MailMessage.MessageID,6,2)+'/'+Copy(NMPOP31.MailMessage.MessageID,8,2);
Memo1.Lines.Assign(NMPOP31.MailMessage.Body);
If NMPOP31.MailMessage.Attachments.Text <> '' then
begin
ShowMessage('附件:'+#10#13+NMPOP31.MailMessage.Attachments.Text);
FileListBox1.Update;
end;
end;
这是我用delphi5.0做的,接受中文没有乱码呀?一切都很正常,用outlook也没问题