Hi,
I need to add a few more people to my distribution list of an automated report that is issued each morning, how do i add this in ? Help.... the code i currently have is below
Dim rng As Range
Dim OutApp As Object
Dim OutMail As Object
With Application
.EnableEvents = False
.ScreenUpdating = False
End With
Set rng = Nothing
On Error Resume Next
Set rng = Selection.SpecialCells(xlCellTypeVisible)
On Error GoTo 0
If rng Is Nothing Then
MsgBox "The selection is not a range or the sheet is protected" & _
vbNewLine & "please correct and try again.", vbOKOnly
Exit Sub
End If
Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(0)
On Error Resume Next
With OutMail
.To = "X"
.CC = "X"
.BCC = "X"
.Subject = "Daily KPI - December Drop Off's Predictor (Full month)"
.HTMLBody = RangetoHTML(rng)
.Display
.Send
End With
On Error GoTo 0
With Application
.EnableEvents = True
.ScreenUpdating = True
End With
Set OutMail = Nothing
Set OutApp = Nothing
Thanks in advance for any help
Paul
Bookmarks