now() function

C

cmied

My sheet needs a real-time clock. I tried the now()
function but it does not automatically update.

Is there a function that will automatically update ?
 
D

David Hager

You cannot run more than one process in Excel at a time. If you run a
procedure that
continually updates the time, you would not be able to do anything else.
 
J

Jez

If you use VBA rather than the NOW function you can
assign it to a button which will update everytime you
press it.....
 
G

GB

cmied said:
My sheet needs a real-time clock. I tried the now()
function but it does not automatically update.

Is there a function that will automatically update ?

See Chip Pearson's site on how to do this sort of thing in VBA.

http://www.cpearson.com/excel/ontime.htm

You can use his code to organise the updating and just use it to set a value
in a cell on your spreadsheet:

Range ("A1") = Now


Hope that helps

Geoff
 
E

Earl Kiosterud

cmied,

Put this in an ordinary module and run it. It'll boot itself continuously.
The clock will stop running while your in Enter or Edit mode, or if another
sub runs continuously.
 
E

Earl Kiosterud

OOPS! Goll-ee. Looks as if someone forgot to paste in the macro.
Couldn't've been moi! Could it?

Sub ClockBump()
Application.OnTime Now() + TimeValue("00:00:01"), "ClockBump"
Range("A1") = Now()
End Sub

Change the range where you want the time to appear. Change the "0:00:01" to
be consistent with how you have the cell time-formatted. For example, if it
doesn't have seconds, then use "0:01:00" for an update every minute.
 

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