Sende flere filer på mail via VBA
Jeg har en stump kode, som kun kan sende en fil på mail vedhæftet, hvis jeg har behov for at sende flere filer på samme mail. VBA henter fil oplysninger i en en access database.End Select
On Error Resume Next
With OutMail
.To = MailNavn
.CC = ""
.BCC = ""
.Subject = SubjNavn
.Body = strBody
.Attachments.Add (strPath & FilNavn)
.Send
End With
Hvordan skal .Attachments.Add (strPath & FilNavn) se ud hvis der er flere filer der skal sendes.