clock

A

Alun Davies

Is there a working clock that I can have on an excel
worksheet? I need to input data on the hour every hour
from a running total. This would make it easier if I can
calculate against a clock. I have no problem with the
calculation. Can I switch a macro "on" once every hour??

Alun Davies
 
E

Ecco

Here is an example, which runs every hour.

Sub RunEveryHour()
Application.OnTime Now + TimeValue("00:01:00"), "RunMe"
End Sub
Sub RunMe()
Range("a1") = Now() 'or what you want this macro to do
RunEveryHour
End Sub

When you start the macro RunEveryHour, it places current
time in cell A1 in every hour.

Ecco
 

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