dwarnimont
Board Regular
- Joined
- Jan 12, 2010
- Messages
- 71
I have the below code embedded within my sheet. my need is to repeat the same type of process but with several different targets like (C4), and have a different MsgBox for each cell and. Not sure if this is still sheet code or macros?
Also, this code was given to me and the LCase is not helpful. I'd like to remove any logic about case. Thanks for this help. Dave
=======================================================================
Private Sub Worksheet_Change(ByVal Target As Range)
Dim msg As String
msg = "Dave doesn't like to do this work, will you do it?"
If Target.CountLarge > 1 Then Exit Sub
If Not Intersect(Target, Range("c4")) Is Nothing Then
If LCase(Target.Value) = "grind-flat" Then
If MsgBox(msg, vbYesNo) = vbNo Then
MsgBox "This will cost you!"
Else
MsgBox "Good girl..."
End If
End If
End If
End Sub
Also, this code was given to me and the LCase is not helpful. I'd like to remove any logic about case. Thanks for this help. Dave
=======================================================================
Private Sub Worksheet_Change(ByVal Target As Range)
Dim msg As String
msg = "Dave doesn't like to do this work, will you do it?"
If Target.CountLarge > 1 Then Exit Sub
If Not Intersect(Target, Range("c4")) Is Nothing Then
If LCase(Target.Value) = "grind-flat" Then
If MsgBox(msg, vbYesNo) = vbNo Then
MsgBox "This will cost you!"
Else
MsgBox "Good girl..."
End If
End If
End If
End Sub