Anyone? Here is what I am using:
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
Dim OutApp As Object
Dim OutMail As Object
Const SendTo As String = "nobody@email.com"
Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)
With OutMail
.To = SendTo
.Subject = ThisWorkbook.Name & " has been amended"
.Body = " The Incident report log has been updated. Ken, is this okay for an update?"
.Send
End With
Set OutMail = Nothing
Set OutApp = Nothing
End Sub
Bookmarks