View Single Post
 
Old 03-04-2023, 01:34 PM
AlanCantor AlanCantor is offline Windows 10 Office 2019
Competent Performer
 
Join Date: Nov 2020
Posts: 137
AlanCantor is on a distinguished road
Default

Maybe something like this?



Code:
Sub Email_Attachment_To_Group()
    Dim OutApp As Object
    Dim OutMail As Object
    Set OutApp = CreateObject("Outlook.Application")
    Set OutMail = OutApp.CreateItem(0)

    With OutMail
        .To = "person1@email.com;person2@email.com"     ' List of addresses to send
        .CC = ""
        .BCC = ""
        .Subject = "Monthly spreadsheet"
        .Body = "Attached is the monthly spreadsheet."
        .Attachments.Add ("C:\Users\123456\Documents\Monthly\test.txt") ' Specify full path to the file to attach
        .Display
    End With
         
    Set OutMail = Nothing
    Set OutApp = Nothing
End Sub
Reply With Quote