Creates an EmbeddedObject from a file path.
An EmbeddedObject built from a file path.
[C#]
EmailMessage m = new EmailMessage("127.0.0.1" );
m.From = "me@mycompany.com";
m.To = "you@yourcompany.com";
m.Subject = "testing email";
m.Body = "what do you think of the new logo?<br><img src=\"cid:logo1\">";
//enable logging for any troubleshooting problems
m.Logging = true;
m.LogPath = "c:\\email.log";
//create the embedded image from a file
EmbeddedObject eo = EmbeddedObject.ParseFile( "logo1", "c:\\temp\\companylogo.gif" );
m.EmbedObject( eo );
//send
m.Send();
[VB.NET]
Dim m As New EmailMessage("127.0.0.1")
m.From = "me@mycompany.com"
m.To = "you@yourcompany.com"
m.Subject = "testing email"
m.Body = "what do you think of the new logo?<br><img src=""cid:logo1"">"
'enable logging for any troubleshooting problems
m.Logging = True
m.LogPath = "c:\email.log"
'create the embedded image from a file
Dim eo As EmbeddedObject = EmbeddedObject.ParseFile("logo1", "c:\temp\companylogo.gif")
m.EmbedObject(eo)
'send
m.Send()