+ Reply to Thread
Results 1 to 3 of 3

Continue counting

  1. #1
    Registered User
    Join Date
    07-17-2016
    Location
    Brazil
    MS-Off Ver
    2016
    Posts
    15

    Question Continue counting

    I have a table with several time records. When I click on one of these records a form with a timer appears to continue counting the time. However the timer resets the time and starts from zero.

    How do I stop the timer from continuing to count the time?


    bntStart = button start timer
    bntPause = button pause timer
    label1 = Time textbox

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.

  2. #2
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,912

    Re: Continue counting

    Have you used variables with global scope? If not, setting dteStopped in bntTop_Click will not make it available to bntStart_Click, so this:

    dteElapsed = dteFinish - dteStart + dteStopped

    becomes, essentially:

    dteElapsed = dteFinish - dteStart + 0

    and finally, since dteFinish and dteStart were both just set to = Time

    dteElapsed = 0 + 0
    Bernie Deitrick
    Excel MVP 2000-2010

  3. #3
    Registered User
    Join Date
    07-17-2016
    Location
    Brazil
    MS-Off Ver
    2016
    Posts
    15

    Re: Continue counting

    How do I get it to continue counting when you already have some time in the textbox?


    Sem título.jpg

+ 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. Replies: 4
    Last Post: 06-17-2014, 08:39 AM
  2. Need loop to continue instead of end
    By lordterrin in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-26-2013, 07:01 PM
  3. vba to add new row and continue new #
    By adamheon in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-21-2013, 03:42 PM
  4. Click ok to continue
    By tkuia in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-13-2010, 03:44 AM
  5. [SOLVED] to continue down in the same row
    By alex178 in forum Excel General
    Replies: 2
    Last Post: 07-08-2006, 12:40 PM
  6. Continue
    By Steph in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-31-2006, 01:55 PM
  7. [SOLVED] Allow code to continue regardless
    By Pat in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-19-2005, 11:06 AM

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