Oct 24, 2001 #1 cyork MIS Joined Apr 4, 2001 Messages 34 Location CA Is there a way to have a macro execute everytime the value in a given cell is changed??? Thanks, Chris
Is there a way to have a macro execute everytime the value in a given cell is changed??? Thanks, Chris
Oct 24, 2001 #2 dsi Programmer Joined Mar 13, 2000 Messages 964 Location US Use the Worksheet_Change event to monitor your target cells. Then, if the target cell is changed, just call your macro. Upvote 0 Downvote
Use the Worksheet_Change event to monitor your target cells. Then, if the target cell is changed, just call your macro.
Oct 24, 2001 #3 vbMax Programmer Joined Jul 16, 2001 Messages 92 Location US You can use the Worksheet_Change event. In the example below, "yourProcedure" is executed whenever cell A1 is changed. Private Sub Worksheet_Change(ByVal Target As Excel.Range) If Target.Address = Range("A1".Address Then Call yourProcedure End If End Sub Upvote 0 Downvote
You can use the Worksheet_Change event. In the example below, "yourProcedure" is executed whenever cell A1 is changed. Private Sub Worksheet_Change(ByVal Target As Excel.Range) If Target.Address = Range("A1".Address Then Call yourProcedure End If End Sub