I am using .SendMail in an Excel VBA Macro to send a workbook to an email address. It works fine, but I needed to send to multiple recipients.
Here was the syntax I started with:
ThisWorkbook.SendMail "email@example.com", "Text for the Subject Line"
When I tried to add multiple addresses, I tried commas, I tried semi-colons, and I tried an Array command, none of which worked.
Finally I realized that I was using messy syntax, and cleaned it up and got it to work this way:
ThisWorkbook.SendMail Recipients:=Array("firstname.lastname@example.org","email@example.com") Subject:="Text for Subject Line"
That allowed me to mail (as an attachment) the workbook to multiple addresses without throwing any errors.
Linda - http://how.best-free-information.com - The "How" Blog