that works perfectly, thank you.
"JE McGimpsey" wrote:
> One way:
>
> Put this the ThisWorkbook Code module:
>
>
> Private Sub Workbook_Open()
> StartCounting bStart:=True
> End Sub
>
> Private Sub Workbook_BeforeClose(Cancel As Boolean)
> StopCounting
> End Sub
>
> Put this in a regular code module:
>
> Public dNextCall As Double
>
> Public Sub StartCounting(Optional bStart As Boolean = False)
> Const dINCREMENT As Date = #00:01:00#
> If Not bStart Then
> With Sheets("Sheet1").Range("A1")
> .Value = .Value + dINCREMENT
> End With
> End If
> dNextCall = Now + dINCREMENT
> Application.OnTime dNextCall, "StartCounting", Schedule:=True
> End Sub
>
> Public Sub StopCounting()
> Application.OnTime dNextCall, "StartCounting", Schedule:=False
> End Sub
>
> Change the Sheet and range, and the increment, to suit.
>
> In article <F9530E4B-7470-4577-9E24-(E-Mail Removed)>,
> AJB <(E-Mail Removed)> wrote:
>
> > I am a cost estimator who works on 2-12 bids a week and I want to add a timer
> > to my template that simply counts up from zero while the workbook is open
> > (and cumulatively each time opened) so I can compare my time usage vs. job
> > profit estimated.
> >
> > I am a programming rookie, thanks for your assistance.
>
|