S
Sean
Hi,
I have a event on a worksheet that is triggered when cell $A$5 is
changed. The problem is when cells are inserted or deleted from the
sheet then I need to update my macro.
Is there a way to target a named range?
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$A$5" Then
MsgBox "Hello"
End If
End Sub
Works
but
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "range name" Then
MsgBox "Hello"
End If
End Sub
Does not.
Any assistance will be appreciated.
Regards.
Sean
I have a event on a worksheet that is triggered when cell $A$5 is
changed. The problem is when cells are inserted or deleted from the
sheet then I need to update my macro.
Is there a way to target a named range?
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$A$5" Then
MsgBox "Hello"
End If
End Sub
Works
but
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "range name" Then
MsgBox "Hello"
End If
End Sub
Does not.
Any assistance will be appreciated.
Regards.
Sean