Archived Forum Post

Index of archived forum posts

Question:

Saving EML files to IIS SMTP queue folder?

Nov 08 '12 at 15:19

If a Chilkat email object is saved to the IIS SMTP queue folder via the emailObject.SaveEml method, will the IIS SMTP process send it correctly?


Answer

A .eml file is MIME format, which is the Internet standard format for email. Assuming that the IIS SMTP process is expecting to find emails in MIME format such that the sender is indicated in the FROM header field, and the recipients are indicated in TO and CC headers, then Yes, it should be possible. However, each email's Message-ID header should be unique. The better solution would be to call mailman.RenderToMime to generate the MIME string that should be saved to a file in the queue directory. For example, in pseudo-code:

string mime = mailman.RenderToMime(emailObject);
// Save the MIME string to a file in the queue directory...