Data validation comments...appearance

mad3

Board Regular
Joined
Sep 15, 2009
Messages
82
I'm trying to get the comments from the cells that are on another sheet to appear when my users hover over cell where drop-down list is.
Please help, Mike in Cali...
 

tonyyy

Well-known Member
Joined
Jun 24, 2015
Messages
1,647
Mike,

If you're comfortable with a vba approach you might consider the following...

Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Dim cmt As Comment
Dim dvRange As Range, r As Range
Set dvRange = Sheets("Sheet2").Range("D4:D7") 'Change to your sheet name and range

If Not Intersect(Target, Range("H4")) Is Nothing Then 'Change to your Data Validation range
    For Each r In dvRange
        If Target.Value = r.Value Then
            Target.ClearComments
            Target.AddComment.Text r.Comment.Text
        End If
    Next r
End If
End Sub
The code should be pasted into the sheet module corresponding to the sheet with the drop down.

Cheers,

tonyyy
 

Forum statistics

Threads
1,085,495
Messages
5,384,002
Members
401,871
Latest member
allemandi

Some videos you may like

This Week's Hot Topics

Top