Cell Change activating macro. How do you make it happen?
Tom:
Thanks for the advice.
The following is exactly what I pasted into the worksheet code sheet:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Address = "$f$5" Then
Msg box "Do something "
End If
End Sub
However, nothing happens when I change the contents of F5 and press enter! When I change
the cell contents, press enter, leave the cell, and then later return and click on it the
"DO SOMETHING" box activates.
Is this the way its supposed to happen?
"Tom Ogilvy" wrote:
It is event code
Right click on the worksheet tab where you want this behavior. Select View
code.
Paste in the code.
|