ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Email to include a saved signature from outlook. (https://www.excelbanter.com/excel-programming/435697-email-include-saved-signature-outlook.html)

Paul Lambson

Email to include a saved signature from outlook.
 
I have this macro that runs fine. What I would like to do is add a
signature from me outlook named "work" at the end of this email. Any
help is appreciated.

Thanks,

Paul




Sub EmailPDF()
Dim MyDate As String
MyDate = Date

ActiveWorkbook.ExportAsFixedFormat xlTypePDF, "c:\sas
\DailyBuildReport" & Format(Date, "mm-dd-yyyy") & ".pdf"

Dim olApp As Outlook.Application
Dim olMail As MailItem

Set olApp = New Outlook.Application
Set olMail = olApp.CreateItem(olMailItem)

With olMail
.To = "
.CC = ""
.Subject = "Daily Build Test " & MyDate
.Body = "Please reference attached."
.Attachments.Add "c:\sas\DailyBuildReport" & Format(Date, "mm-
dd-yyyy") & ".pdf"
'.Display
.Send

End With

Set olMail = Nothing
Set olApp = Nothing




End Sub


Ron de Bruin

Email to include a saved signature from outlook.
 
Start here Paul
http://www.rondebruin.nl/mail/folder3/signature.htm


--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Paul Lambson" wrote in message ...
I have this macro that runs fine. What I would like to do is add a
signature from me outlook named "work" at the end of this email. Any
help is appreciated.

Thanks,

Paul




Sub EmailPDF()
Dim MyDate As String
MyDate = Date

ActiveWorkbook.ExportAsFixedFormat xlTypePDF, "c:\sas
\DailyBuildReport" & Format(Date, "mm-dd-yyyy") & ".pdf"

Dim olApp As Outlook.Application
Dim olMail As MailItem

Set olApp = New Outlook.Application
Set olMail = olApp.CreateItem(olMailItem)

With olMail
.To = "
.CC = ""
.Subject = "Daily Build Test " & MyDate
.Body = "Please reference attached."
.Attachments.Add "c:\sas\DailyBuildReport" & Format(Date, "mm-
dd-yyyy") & ".pdf"
'.Display
.Send

End With

Set olMail = Nothing
Set olApp = Nothing




End Sub



All times are GMT +1. The time now is 12:19 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com