Hey guys, as the name says, I'm VB challenged. I managed to piece together a code that sends an email to certain users when a document is updated. It works great, but I would really like for it to also list the data/info of the cell or row that was modified. The workbook is basically a log file. Here's what I have...
Private Sub Worksheet_Change(ByVal Target As Range)
Dim rng1 As Range
Set rng1 = Intersect(Range("C:C"), Target)
If rng1 Is Nothing Then Exit Sub
Application.EnableEvents = False
rng1.Offset(0, 1).Value = Date
Application.EnableEvents = True
Dim OutApp As Object
Dim OutMail As Object
Const SendTo As String = "john.doe@anon.com;jane.doe@anon.com"
Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)
With OutMail
.To = SendTo
.Subject = " New Prototype Request"
.Body = " You are receiving this auto-message because this user has issued a new prototype request. Please check the log for the number and required documentation"
.Send
End With
Set OutMail = Nothing
Set OutApp = Nothing
End Sub
Thanks in advance!
Bookmarks