Hi all,
I wish to set up a condition on cell whereby a comment box appears automatically if the user enters a certain value into that cell, BUT another cell (D12) is left blank.
If the 'conditional' cell is blank (or equal to zero), and the cell itself (D29) is not equal to zero, then I want a comment appears to say "error".
The code I have tried using is shown below. FYI it works with one criteria ie no "And Range("D29:AP29")", but i need both criteria to be accounted for in order for the condition to work.
Any help would very much appreciated!!![]()
Private Sub Worksheet_Calculate() Dim rCell As Range Set rCell = Range("D29:AP29") On Error Resume Next rCell.Comment.Delete On Error GoTo 0 If Range("D12:AP12") <> 0 And Range("D29:AP29") = 0 Then rCell.AddComment ("error") End Sub
Thanks,
Michael
Bookmarks