EmilVictor
New member
- Joined
- Oct 15, 2018
- Messages
- 5
- Reaction score
- 0
- Points
- 0
- Excel Version(s)
- 2012
here is my code so far. it sends all the excel file. but I need 1 sheet to be excluded.
Code:
Dim OutApp As Object
Dim OutMail As Object
Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(0)
On Error Resume Next
With OutMail
.To =
.CC =
.BCC = ""
.Subject = ActiveWorkbook.Name
.body = "Hi" & vbNewLine & vbNewLine & _
.Attachments.Add ActiveWorkbook.FullName
.Display
End With
On Error GoTo 0
so like I have 5 sheets.
I just need 4 sheets to be send to email.
like sheet1 and sheet 2 and sheet and sheet 4 without sheet 5
Set OutMail = Nothing
Set OutApp = Nothing
Last edited by a moderator: