title: Sending Outlook Email with embedded image using VBS
body: <p>I am currently using the following VBS script to send an email and it works fine, however the image is sent as an attachment.  I would instead like to embed the image into the email.  I understand that I must reference the attachment in the HTML body of the email but I am struggling to do this.</p>
  
  <p>Any suggestions?</p>
  
  <pre><code>Dim ToAddress
  Dim FromAddress
  Dim MessageSubject
  Dim MyTime
  Dim MessageBody
  Dim MessageAttachment
  Dim ol, ns, newMail
  MyTime = Now
  
  ToAddress = "email@address.com"
  MessageSubject = "Auto Stats " &amp; MyTime
  MessageBody = "Stats Attached" &amp; vbCrLf &amp; "Produced at " &amp; MyTime
  MessageAttachment = "P:\stats.png"
  Set ol = WScript.CreateObject("Outlook.Application")
  Set ns = ol.getNamespace("MAPI")
  Set newMail = ol.CreateItem(olMailItem)
  newMail.Subject = MessageSubject
  newMail.Body = MessageBody
  newMail.RecipIents.Add(ToAddress)
  newMail.Attachments.Add(MessageAttachment)
  newMail.Send
  </code></pre>