+ Reply to Thread
Results 1 to 8 of 8

Force Sheet to refresh every XX minutes

  1. #1
    Forum Contributor Grimace's Avatar
    Join Date
    05-04-2009
    Location
    Gold Coast, Australia
    MS-Off Ver
    Excel 2013 and Office 365 Plus
    Posts
    380

    Force Sheet to refresh every XX minutes

    Hi all

    I am setting up a draw for a competition, and want to make it as easy as possible for the people to read.

    To assist in this, i want to highlight any rounds in the draw that have already been started, therefore directing their eyes to the next round to be played. To achieve this, i am just using a conditional format to change the background colour once the Now() time is past the start time of that round.

    My issue is that unless i manually change something on the sheet, the formula =now() does not refresh.

    It could be an extended period between making changes, so i want to get it to refresh every 5 minutes, that way if the start time for a round has passed it will highlight.

    Is there a function to force the sheet to refresh periodically?

    Thanks in advance

    Darren.
    Handy things to keep in mind:

    Click *, if my suggestion has helped you
    If your problem is solved, then please mark the thread as SOLVED

    Sharing is Caring .... spread the knowledge

  2. #2
    Valued Forum Contributor AlvaroSiza's Avatar
    Join Date
    09-19-2007
    Location
    Staffordshire
    MS-Off Ver
    2007
    Posts
    591

    Re: Force Sheet to refresh every XX minutes

    How about:

    In the ThisWorkbook code section:
    Please Login or Register  to view this content.
    And in a standard module:
    Please Login or Register  to view this content.
    The .calculate should envoke a refresh. Please reply with results as this is untested.
    Perhaps it was the Noid who should have avoided me...
    If you are satisfied with my solution click the small star icon on the left. Thanks
    1. Make a copy of your workbook and run the following code on your copy (just in case)
    2. With excel open, press ALT+F11 to open the Visual Basic Editor (VBE). From the "Insert" menu, select "Module".
    3. Paste the code from above into the empty white space. Close the VBE.
    4. From the developer tab, choose "Macros", select the Sub Name, and click "Run".

  3. #3
    Forum Contributor Grimace's Avatar
    Join Date
    05-04-2009
    Location
    Gold Coast, Australia
    MS-Off Ver
    Excel 2013 and Office 365 Plus
    Posts
    380

    Re: Force Sheet to refresh every XX minutes

    Thanks for that .... sorry to sound vague ... is a standard module just under Sheet 1 etc?

  4. #4
    Forum Contributor Grimace's Avatar
    Join Date
    05-04-2009
    Location
    Gold Coast, Australia
    MS-Off Ver
    Excel 2013 and Office 365 Plus
    Posts
    380

    Re: Force Sheet to refresh every XX minutes

    I just tried it and received a "Compile Error"

    Compile Error.jpg

  5. #5
    Forum Contributor Grimace's Avatar
    Join Date
    05-04-2009
    Location
    Gold Coast, Australia
    MS-Off Ver
    Excel 2013 and Office 365 Plus
    Posts
    380

    Re: Force Sheet to refresh every XX minutes

    Any ideas on the compile error please?

  6. #6
    Forum Expert
    Join Date
    08-12-2012
    Location
    Sydney, Australia
    MS-Off Ver
    Excel 2010
    Posts
    5,636

    Re: Force Sheet to refresh every XX minutes

    dont know if you resolved this yourself but see attached sheet with working module

    though do not understand how the conditional formatting bit would work
    you update now once then what happens?

    you would actually need something more on...off ...on..off etc wouldnt you?

    this is what i am referring to
    http://msdn.microsoft.com/en-us/libr.../ff193220.aspx

    alter for your need of course
    Attached Files Attached Files
    Last edited by humdingaling; 07-19-2013 at 04:00 AM.
    If you are satisfied with the solution(s) provided, please mark your thread as Solved.
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  7. #7
    Forum Contributor Grimace's Avatar
    Join Date
    05-04-2009
    Location
    Gold Coast, Australia
    MS-Off Ver
    Excel 2013 and Office 365 Plus
    Posts
    380

    Re: Force Sheet to refresh every XX minutes

    Thanks Humdingaling

    The formatting piece is done by setting the Conditional formatting against the time.
    So as the sheet goes through and autorefreshes, if the time is earlier than now(), it changes the formatting.
    The issue i had was keeping it updating the now() function regularly ... will give this a shot thanks

  8. #8
    Forum Expert
    Join Date
    08-12-2012
    Location
    Sydney, Australia
    MS-Off Ver
    Excel 2010
    Posts
    5,636

    Re: Force Sheet to refresh every XX minutes

    reason i asked is because now() will always be now() when you update it

    how does it know the different between now() and the now() you did 5 minutes ago...that is why i suggested the "blinking" cell

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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