I can't imagine why you want to do this.
Is it not just as simple (or simpler) to right click the mouse to Add/Edit/Delete a comment ?
Anyway, here's three macros :-
Sub Add_Comment()
Dim C As Comment
On Error Resume Next
Set C = ActiveCell.Comment
On Error GoTo 0
If Not C Is Nothing Then
MsgBox "There is already a comment in the active cell."
Else
With ActiveCell
.AddComment "This is my comment"
.Comment.Shape.TextFrame.AutoSize = True 'Delete this line if you don't need to auto size the comment
End With
End If
End Sub
Sub Edit_Comment()
Dim oldC As String
Dim newC As String
With ActiveCell
On Error Resume Next
oldC = .NoteText
On Error GoTo 0
newC = InputBox(prompt:="Enter a comment. " & _
Chr(13) & "Selecting cancel will erase the comment", _
Default:=oldC)
.NoteText newC
End With
End Sub
Sub Delete_Comment()
ActiveCell.ClearComments
End Sub