View Single Post
  #3   Report Post  
Fadi Chalouhi
 
Posts: n/a
Default

Insert the following code in the worksheet_change macro of the relevant
worksheet :
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$A$2" And Target.Value = "1" Then
' Run your macro
End If
End Sub

This assumes the following :
(1) the cell you are monitoring is A2 (make sure you put the $ in the
address)
(2) the value you are monitoring is 1
(3) you only want your macro to run when cell A2 gets modified to 1.
(4) if you want your macro to run every time anything changes in the
worksheet (and when cell A2 is 1) then remove the Target.Address
condition.

HTH

Fadi
www.chalouhis.com/XLBLOG