macro til send post
Hejjeg har en macro jeg bruger til at sende en excel mapppe med.
hvordan sætter jeg 2 modtager ind, er det bare med et komma imellem eller ?
koden er her....
Sub SendEmail()
Dim olApp As Object
Dim olNameSpace As Object
Dim olMail As Object
Dim stRecipient As String, stAttachment As String
ActiveWorkbook.Save
stRecipient = "test@excel.dk"
stAttachment = ThisWorkbook.FullName
Set olApp = CreateObject("Outlook.Application")
'hvis der skal bruges et logon
'Set olNameSpace = olApp.GetNamespace("MAPI")
'olNameSpace.Logon "UserName", "Password"
Set olMail = olApp.CreateItem(0)
With olMail
.Subject = "test"
.Recipients.Add stRecipient
.Body = "med venlig hilsen test"
.Attachments.Add stAttachment
.Send
End With
End Sub
eller hvordan gør man det så
