using hyperlinks or macro buttons to time stamp

S

sunroyal

I am currently using this code to time stamp one cell,

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
With Target
If .Count > 1 Then Exit Sub
If Not Intersect(Range("A2:CL2"), .Cells) Is Nothing Then
Application.EnableEvents = False
If IsEmpty(.Value) Then
.Offset(0, 1).ClearContents
Else
With .Offset(0, 1)
.NumberFormat = "dd mmm yyyy h:mm:ss"
.Value = Now
End With
End If
Application.EnableEvents = True
End If
End With
End Sub


Can I do this to two cells, using a hyperlink, as in:

a1=start timer
a2=end timer

It is being used to track call center transaction times.

Thanks, all. Lan
 
F

Frank Kabel

Hi
you may explain which are the conditions to create a time stamp (if
both cells A1, A2 are filled, etc.)
you may also explain there the time stamp should be stored
 
S

sunroyal

If you click the hyperlink in a1, it places the current time in a2
(time start), if you click the hyperlink in a15, then again it place
the current time in a16. A17 would then be the difference between a1
and a2. Total tracked time. This would have to repeate thru to row bb
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top