P
plh
Hello all,
When a user enters data in (say) B:6, I need to have the date of the entry
appear in B:5, and the Time in D:5. The following does it OK in one respect:
When the user deletes the data, that date (& time) go away. They re-appear when
new data is added. BUT.... it keeps regenerating so that the times & dates of
existing entries all end up the same when the user enters new data, reopens the
sheet, or does anything else that causes the sheet to refresh. Here is the code:
(Date function only: the Time function is similar)
Function DateStamp(varTheCell)
If varTheCell.Value <> "" Then
DateStamp = Date
Else
DateStamp = ""
End If
End Function
I mean, I can see why the regens happen. I tried to rewrite it to hold off the
update based on what appears in the cell with the DateStamp function in it, but
Excel (97) complained of a circular reference. Is there some way out of my
dilemma?
Thanking everyone in advance,
-plh
I keep hitting "Esc", but I'm still here!
When a user enters data in (say) B:6, I need to have the date of the entry
appear in B:5, and the Time in D:5. The following does it OK in one respect:
When the user deletes the data, that date (& time) go away. They re-appear when
new data is added. BUT.... it keeps regenerating so that the times & dates of
existing entries all end up the same when the user enters new data, reopens the
sheet, or does anything else that causes the sheet to refresh. Here is the code:
(Date function only: the Time function is similar)
Function DateStamp(varTheCell)
If varTheCell.Value <> "" Then
DateStamp = Date
Else
DateStamp = ""
End If
End Function
I mean, I can see why the regens happen. I tried to rewrite it to hold off the
update based on what appears in the cell with the DateStamp function in it, but
Excel (97) complained of a circular reference. Is there some way out of my
dilemma?
Thanking everyone in advance,
-plh
I keep hitting "Esc", but I'm still here!