View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Jim Thomlinson Jim Thomlinson is offline
external usenet poster
 
Posts: 5,939
Default Run Procedure when The Value of A Cell Changes

You are talking about Event code. Right click the sheet tab you want to catch
the events on and select View Code. The VBE will open. Just above the code
window to the left is a drop down of the Object. Change it from General to
Worksheet. A code stub will be created for you base on selection change. In
the drop down next to the one you just changed is a list of the events.
Select Change and you will get a code stub something like this...

Private Sub Worksheet_Change(ByVal Target As Range)

End Sub

Target is the cell that was changed so just do something like this...

Private Sub Worksheet_Change(ByVal Target As Range)
if target.Address = "$A$1" then msgbox "Tada"
End Sub

--
HTH...

Jim Thomlinson


"R Tanner" wrote:

Hi,

I need to run a procedure when the value of a specific cell changes..
How would I do that?