Home |
Search |
Today's Posts |
|
#1
![]() |
|||
|
|||
![]()
Private Sub Worksheet_Change(ByVal Target As Range)
Const WS_RANGE As String = "H1:H10" On Error GoTo ws_exit: Application.EnableEvents = False If Not Intersect(Target, Me.Range(WS_RANGE)) Is Nothing Then With Target .Offset(0, 1).Value = Format(Now, "dd mmm yyyy hh:mm:ss") End With End If ws_exit: Application.EnableEvents = True End Sub 'This is worksheet event code, which means that it needs to be 'placed in the appropriate worksheet code module, not a standard 'code module. To do this, right-click on the sheet tab, select 'the View Code option from the menu, and paste the code in. -- HTH RP (remove nothere from the email address if mailing direct) "Geoffrey" wrote in message ... I want to set up a work activity log. It would be useful if the date and time were automatically inserted in a cell adjacent to the activity as soon as the type of activity is recorded, thus giving the start time. Any ideas? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Using VLOOKUP with a Date and Time | Excel Discussion (Misc queries) | |||
How do I calculate if a date is in a certain time frame? | Excel Worksheet Functions | |||
Imported Date & Time format with calcs. managed in excel from imrp | Excel Worksheet Functions | |||
Automatically enter date and time but only update once. | New Users to Excel | |||
Help - Information with time and date | Excel Discussion (Misc queries) |