very strange -
i lifted this code from ozgrid site (thank you, ozgrid, and your long term member PCI) -
Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
If (Target.Address = "$A$1") Then
Cells(2, 2) = Cells(2, 2) + 1
' Your Code
Application.EnableEvents = True
End If
End Sub
when i use the sample file that came with it, it works - i change the value in cell A1, and value in cell B2 increases by one. however, if i disturb it in a slightest way, it stops working - e.g. if i change the trigger cell to "$A$2", or move the procedure to my own spreadsheet, etc.
what is it? i have not a slightest clue..
using excel 2007 (although the sample file is .xls)
thanks,
l
i lifted this code from ozgrid site (thank you, ozgrid, and your long term member PCI) -
Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
If (Target.Address = "$A$1") Then
Cells(2, 2) = Cells(2, 2) + 1
' Your Code
Application.EnableEvents = True
End If
End Sub
when i use the sample file that came with it, it works - i change the value in cell A1, and value in cell B2 increases by one. however, if i disturb it in a slightest way, it stops working - e.g. if i change the trigger cell to "$A$2", or move the procedure to my own spreadsheet, etc.
what is it? i have not a slightest clue..
using excel 2007 (although the sample file is .xls)
thanks,
l