Thanks to all you guys that have helped me so far. What i now need to do is use the time stamp that i have previously been given ... but to add to text already in the cell rather than copy over the cells text. The code i am currently using is:
Sub TimeStampOn() ActiveSheet.OnEntry = "Stamper" End SubSub Stamper() On Error Resume Next ActiveCell.ClearComments On Error GoTo 0 ActiveCell.Range("A1").Value = Date + Time End SubWhat i am trying to achieve is a list of these dates and times in 1 cell... so if i stamp it once... when i stamp the second time it just lists the time below the previous one in the same cell rather than copying over it. Is this possible?Sub TimeStampOff() ActiveSheet.OnEntry = "" End Sub![]()
Last edited by VBA Noob; 11-07-2008 at 04:38 AM.
Hi, You could try this line in you code:-
Regards MickActiveCell.Value = ActiveCell.Value & Chr(10) & Date + Time
Nope... no luck. What does that code do? Hasnt seemed to change anything...
I can't find the OnEntry property at all, even in the object browser; is it still supported?
What are you trying to do?
Microsoft MVP - Excel
Entia non sunt multiplicanda sine necessitate
Hi, If you just use the code line I sent you in a CommanButton on your sheet. Every time you run the code in the same Activecell, it will add the time & date to the cell along with the original cell information.
Mick
Last edited by MickG; 11-06-2008 at 11:06 AM.
ah... thats great thanks... do you know how i can get rid of the seconds? i have tried formatting the cell itself to dd/mm/yyyy hh:mm but it still displays seconds... i would still like the time but just not seconds ... can anyone help?
Try:-
Regards MickActiveCell.Value = ActiveCell.Value & Chr(10) & Format(Date + Time, "dd/mm/yyyy hh:mm")
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks