i have a note pertaining to E4. I have tried to write code so that if I double click the note that the cursor will go to cell E4
When clicking on the note , nothing happens
It would be appreciated if someone could amend my code
When clicking on the note , nothing happens
It would be appreciated if someone could amend my code
Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim rng As Range
Dim noteRange As Range
Set rng = Me.Cells.SpecialCells(xlCellTypeComments) ' Get all cells with notes
If rng.Cells.Count > 0 Then
For Each noteRange In rng
If Not noteRange.Comment Is Nothing Then
If Not Intersect(Target, noteRange.Comment.Shape.TopLeftCell) Is Nothing Then
Application.Goto Me.Range("E4") ' Go to the specified cell (E4)
Exit Sub
End If
End If
Next noteRange
End If
End Sub [code]