Sending an email with signature. Need some help.



I am trying to write a macro that with send out an email. (This is being
launched from excel)
When I run the macro, it puts the signature, but all embedded images are not
included and show the boxes where they should be

I have tried the following:

sigstring =

If Dir(sigstring) <> "" Then
Signature = GetBoiler(sigstring)
Signature = ""
End If
On Error GoTo 0

For Each oAccount In OutApp.Session.Accounts
If oAccount.AccountType = olPop3 Then
If oAccount.DisplayName = "(e-mail address removed)" Then
MsgBox "Sending out!"

Dim oMail As Outlook.MailItem
Set oMail = OutApp.CreateItem(olMailItem)
oMail.To = emailname
oMail.CC = ""
oMail.BCC = bbcname
oMail.Subject = "Here is the subject..."
oMail.HTMLBody = RangetoHTML(rng) '& vbNewLine & vbNewLine &
oMail.Attachments.Add ("C:\notary\invoice.pdf")
oMail.SendUsingAccount = oAccount

Range("L" & rowi).Select
ActiveCell.FormulaR1C1 = ActiveCell.FormulaR1C1 & " Sent: " &
Format(Now, "mmm-d-yyyy hh:mm")


End If

End If

Function GetBoiler(ByVal sFile As String) As String
'Dick Kusleika
Dim fso As Object
Dim ts As Object
Set fso = CreateObject("Scripting.FileSystemObject")
Set ts = fso.GetFile(sFile).OpenAsTextStream(1, -2)
GetBoiler = ts.readall
End Function



Michael Bauer [MVP - Outlook]

Here's a sample for how to do that with the Redemption (

Sorry, the description isn't translated yet. It demos how to insert an image
or audio file in an html e-mail. You can use a placeholder (@0) to determine
where to insert it. Without using the plpaceholder, the image will be
appended at the end.

Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
Organize eMails:

Am Sat, 1 Sep 2007 10:48:41 -0700 schrieb Bruce:

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question