s***@gmail.com
2012-07-09 18:27:01 UTC
I have the following code and I keep getting an error at line "Set timestamp = Target.Offset(0, -3)". What seems to be the problem. What I would like to do is whenever cells in column C is modified, corresponding column A will get timestamped.
TIA,
kray
---
Private Sub Worksheet_Change(ByVal Target As Range)
'MsgBox Target.Address
Dim timestamp As Range
Set timestamp = Target.Offset(0, -3)
'MsgBox timeStamp.Address
If timestamp.Value = "" Then
MsgBox "Nothing in there"
timestamp.Value = Now
Else
MsgBox timestamp
End If
End Sub
TIA,
kray
---
Private Sub Worksheet_Change(ByVal Target As Range)
'MsgBox Target.Address
Dim timestamp As Range
Set timestamp = Target.Offset(0, -3)
'MsgBox timeStamp.Address
If timestamp.Value = "" Then
MsgBox "Nothing in there"
timestamp.Value = Now
Else
MsgBox timestamp
End If
End Sub