Is there a way to save the email as a file while using MailKit c#?
Asked Answered
W

1

10

I would like to save the entire email to the disk with all the headers instead to relay to an SMTP server using MimeKit, is this possible?.

I am aware that the Message itself can be written into a file.

Wynd answered 3/7, 2016 at 5:49 Comment(0)
E
14

Yes. You can do:

message.WriteTo (fileName);
Embracery answered 4/7, 2016 at 9:43 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.