Hi, I have a code to send outlook mail with a attachment and it is working fine but how can I improve it and send 2 or multiple excels in same folder ..Please suggest
Code:
Sub attachment()
Dim strlocation As String
Dim outapp As Object
Dim outmail As Object
Set outapp = CreateObject("outlook.application")
Set outmail = outapp.createitem(0)
strlocation = "C:\Users\ah0118261\Desktop\Goals 2016-FPM Team.pptx"
With outmail
.To = ""
.CC = ""
.BCC = ""
.Subject = "Training Structure"
.Body = "Please write your content"
.Attachments.Add (strlocation)
.display
End With
Set outmail = Nothing
Set outapp = Nothing
With Application
.ScreenUpdating = True
.EnableEvents = True
End With
End Sub
Last edited by a moderator: