How to email an embedded object

  • Thread starter Thread starter Tagwim
  • Start date Start date
T

Tagwim

Hello all,

I am looking to attach an embedded PDF file in an Excel Worksheet to a
outlook email. Has anyone done this before? Any help would be greatly
appreciated.

Thank you in advance

Rob
 
Rob,

Here's an example:

Sub SendEmail()
Dim OutApp As Object, OutMail As Object
Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)
On Error Resume Next
With OutMail
.To = ""
.CC = ""
.Subject = ""
.Attachments.Add "C:\filename.pdf"
.Display
End With
On Error GoTo 0
Set OutMail = Nothing
Set OutApp = Nothing
End Sub
 
Dan,

Thank you but I need to attach an Embedded PDF file, one that is not stored
on disk.

Rob
 

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

Back
Top