+ Reply to Thread
Results 1 to 8 of 8

Real time clock or timer

  1. #1
    Registered User
    Join Date
    09-14-2018
    Location
    Netherlands
    MS-Off Ver
    2013
    Posts
    8

    Real time clock or timer

    Hello all,

    I am trying to find a solution to the following problem:
    In column E, various arrival times can be entered and in column F, a letter needs to be chosen from a dropdown menu (A, S or T). After entering the arrival time and choosing the corresponding letter, Column I needs to show a timer/countdown. For example:

    Expec | Arriv | ? | TIME LEFT
    08:30 | 09:00 | A | [Countdown of 48 hours]
    09:00 | 09:25 | S | [Countdown of 24 hours]
    10:00 | 10:15 | T | [Countdown of 4 hours]

    I can not seem to get the countdown working real time. After doing some extensive research I think there are two options:
    The first one is to put somewhere a real time dynamic clock, so I can calculate a deadline for example and subtract the real time dynamic clock from the deadline. The only problem I have now is that I need to manually refresh (F9) every second....

    The 2nd option is to build in a timer after entering the arrival time (and choosing the letter). I have found a few examples of countdown timers online, however, most of them, when you execute, all the times in the whole excel file are counting down or they don't work after entering the arrival time or it can not handle different countdown timers in each row.

    Is there anyone that can help?

    Many thanks in advance.

  2. #2
    Valued Forum Contributor PFDave's Avatar
    Join Date
    05-17-2012
    Location
    Milton Keynes, England
    MS-Off Ver
    Excel 2013
    Posts
    1,067

    Re: Real time clock or timer

    You need to use VBA for this and you can ask the code to 'refresh' every second.

    The issue you have is that if this is to be a working file (as in you need to be able to go in and update cells etc) then refreshing every second will make it terribly laggy

    I assume with the countdown you will want to know when you're reaching the deadline so maybe refreshing in 5 minutes intervals would be sufficient?
    Please do add reputation where you see fit, it's nice to be nice and we all enjoy a pat on the back

    Please also mark your thread as solved once it has been.

  3. #3
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,933

    Re: Real time clock or timer

    Hi, welcome to the forum

    You could perhaps add the 48 hours to whatever you are measuing against, then compare that to a =NOW() value?
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  4. #4
    Registered User
    Join Date
    09-14-2018
    Location
    Netherlands
    MS-Off Ver
    2013
    Posts
    8

    Re: Real time clock or timer

    Quote Originally Posted by PFDave View Post
    You need to use VBA for this and you can ask the code to 'refresh' every second.

    The issue you have is that if this is to be a working file (as in you need to be able to go in and update cells etc) then refreshing every second will make it terribly laggy

    I assume with the countdown you will want to know when you're reaching the deadline so maybe refreshing in 5 minutes intervals would be sufficient?
    Yes that it's true every 1 minute or 5 minutes refresh would be sufficient.
    Also, indeed it needs to be a working file.

    How difficult is it to make a VBA to refresh the file every x minute(s)?
    Last edited by prbr; 09-14-2018 at 04:28 AM.

  5. #5
    Registered User
    Join Date
    09-14-2018
    Location
    Netherlands
    MS-Off Ver
    2013
    Posts
    8

    Re: Real time clock or timer

    Quote Originally Posted by FDibbins View Post
    Hi, welcome to the forum

    You could perhaps add the 48 hours to whatever you are measuing against, then compare that to a =NOW() value?

    If I understand correct, the NOW function does not update automatically right?

    So after 10 minutes the output of the NOW function would still be the same as 10 min ago ?

  6. #6
    Valued Forum Contributor PFDave's Avatar
    Join Date
    05-17-2012
    Location
    Milton Keynes, England
    MS-Off Ver
    Excel 2013
    Posts
    1,067

    Re: Real time clock or timer

    Please Login or Register  to view this content.

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,933

    Re: Real time clock or timer

    Quote Originally Posted by prbr View Post
    If I understand correct, the NOW function does not update automatically right?

    So after 10 minutes the output of the NOW function would still be the same as 10 min ago ?
    Correct, it does not, but it would change with ANY WS change or with F5
    (VBA would be a better option though)

  8. #8
    Registered User
    Join Date
    09-14-2018
    Location
    Netherlands
    MS-Off Ver
    2013
    Posts
    8

    Re: Real time clock or timer

    Quote Originally Posted by PFDave View Post
    Please Login or Register  to view this content.

    This solved it. Thank you.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] VBA user forms queries to have live clock to track real time
    By NikhilDixit in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-27-2017, 10:05 AM
  2. Real time timer
    By serenitylai in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-25-2017, 12:59 PM
  3. [SOLVED] real-time excel clock
    By luv2glyd in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-24-2016, 08:23 PM
  4. [SOLVED] Can't Stop Live Time / Real Time Clock
    By puuts in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 03-03-2014, 12:39 PM
  5. [SOLVED] Real Time Clock Encountering Error Upon Userform Close
    By Stonesteel15 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-28-2012, 11:51 PM
  6. Real Time Clock in Cell
    By phillija in forum Excel General
    Replies: 3
    Last Post: 04-27-2010, 02:07 PM
  7. real time countdown timer function with ticker
    By mrhzoer in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 08-27-2008, 10:32 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1