title: .net Core Mailkit send attachement from array
body: <p>I am testing .Net Core MVC, which does not support System.Net.Mail, the only alternative I found is Mailkit, works well but can't figure out how to send attachments that I have stored in my database as binary.  I used the following in MVC 5:</p>
  
  <pre><code>     var mail = new MailMessage();
       mail.Attachments.Add(new Attachment(new MemoryStream(attachment), 
       attachmentName, attachmentType));
  </code></pre>
  
  <p>How can I do it in MailKit.</p>