View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
G and (ajk) G and (ajk) is offline
external usenet poster
 
Posts: 8
Default E-mail macro - how do I attach multiple attachments?

Hi,

I am using the macro below to send e-mails out to customers.

Sub Mail_workbook_Outlook()
Dim OutApp As Object
Dim OutMail As Object
Dim cell As Range
Dim strto As String

For Each cell In ThisWorkbook.Sheets("Sheet1") _
.Columns("a").Cells.SpecialCells(xlCellTypeConstan ts)
If cell.Value Like "*@*" Then
strto = strto & cell.Value & ";"
End If
Next
strto = Left(strto, Len(strto) - 1)

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(0)
With OutMail
.To = ""
.CC = ""
.BCC = strto
.Subject = "This is the Subject line"
.Body = "Hi there"
.Attachments.Add ("")
.Send 'or use .Display
End With
Set OutMail = Nothing
Set OutApp = Nothing
End Sub

(I know that there isn't a command in there to quit outlook). Anyway, I
know how to attach one document, but is there a way using this macro that I
can send a message with multiple attachments? If so, can someone please tell
me how?

THANKS!