This project is read-only.

SMTP, Get MessageId

Apr 23, 2013 at 10:32 AM
Edited Apr 23, 2013 at 10:36 AM

I would like to get email MessageID (generated remotely by Smtp server) after I sent it with SmtpClient. It is possible?
Apr 23, 2013 at 12:13 PM

I think it is impossible because MessageID is generated by remote server as you say.
But you can add your own id to SmtpMessage object by below code.

SmtpMessage mg = new SmtpMessage();
mg["X-Your-ID"] = "12345";

It may meet your requirement.