Hello fratello,
Here is the amended version of the macro. Let me know the results.
Private Sub Worksheet_Change(ByVal Target As Range)
Dim oComment As Comment, cell As Range, Rng As Range
Dim Text As String, OldText As String
If Intersect(Target, Range("A:B,D:G,T:Z")) Is Nothing Then Exit Sub
Text = InputBox("Please enter your comment below. Click OK when you are done.")
For Each Rng In Target.Areas
For Each cell In Rng
Set oComment = cell.Comment
If oComment Is Nothing Then
Set oComment = cell.AddComment
oComment.Shape.TextFrame.Characters.Text = "Entered: " & Format(Now, "mmm dd, yyyy h:mm AM/PM") & " " & Text & vbCrLf _
& "Value: " & Target & vbCrLf
oComment.Shape.TextFrame.AutoSize = True
Else
OldText = oComment.Text
oComment.Shape.TextFrame.Characters.Text = OldText & "Changed: " & Format(Now, "mmm dd, yyyy h:mm AM/PM") & " " & Text & vbCrLf _
& "Value: " & Target & vbCrLf
End If
Next cell
Next Rng
End Sub
Bookmarks