Counting Timer - Up and Down

Bright01
Bright01 used Ask the Experts™
on
After great work by 4 EE Pros, Brad Yandt, Professor Jim Jam, Ramin and Roy Cox, I got a great little Countdown Timer that I can use.  As generally the case, the  more I worked with this Team of professionals, the more I realized I could make this even better and albeit simpler.

So here is the ask.  I'm attaching the work that has been done on the Countdown Timer + a Form that I have produced to demonstrate what this should look like.  I thought I'd use a form so you can call it up, set the timer and then hide it easily.  The original countdown timer works by using the two Worksheets.  The one I'm asking for uses the Form only.  What is different also is that it should count down if a number is entered into the Excel cell (in the form) that is formatted for time.  If the number is not 0:00:00, then when you press the Count! button it should count up (no set ending).  If a number is entered, say 1:30:00 it would then realize it's a count down and when you click on Count, it counts down and then announces  when the time is up (Roy put this in the original code -- way cool!).  

That's it!   Hope you engage with this one.  It's a little bit more complicated but I'm looking forward to learning how to do this by watching you pros.

Thank you in  advance,


B.
Countdown-Timerv6.3.xlsb
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Top Expert 2016

Commented:
computers aren't that smart. if cell is blank or zero count up, if valid value count down..

Author

Commented:
What?   If you "fire" the Count! Macro, it can't check  to see if Cell<> or = to -0-, so begin count, otherwise, take the number and count down?

B.
Top Expert 2016

Commented:
The original way that I read it was, if there is a value it was ambiguous whether or not to count up or count down. It appears I was mistaken
Ensure you’re charging the right price for your IT

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

Roy CoxGroup Finance Manager

Commented:
You haven't used any code in the form from what I can see, I'll take a look later.

Author

Commented:
Roy,  I'm not skilled at moving code from Modules and Worksheets into Forms.  I think the code you guys put together before did the job so most of it can be transferred into the form.  EXCEPT for the streamline of determining count up  or count down.

Thank you,

B.
Roy CoxGroup Finance Manager

Commented:
I created a UserForm with a Timer on a few years ago. I'll try to find it and adapt it.
Roy CoxGroup Finance Manager

Commented:
This example has a Start, Stop & Pause Button. Check it out and let me know if it is on the right track. If it is I need to figure out the count down part.

I'll try to take a look tomorrow.

Author

Commented:
Roy,

Thanks for the effort.  Did you mean to attach something?

B.
Roy CoxGroup Finance Manager

Commented:
Sorry, I was late home and in a rush. Must have not clicked the attach button.

Author

Commented:
Ha!  Roy, still no attachment!  Get some rest.

B.
Roy CoxGroup Finance Manager

Commented:
Don't know why it's not attaching
EE_Timer-v1.02.xlsm

Author

Commented:
Roy,  Welcome back!  Almost there!  Very well done so far;

Two items;

There needs to be a reset capability to clear the Countdown/Countup cells.  And 2, I can't get the countdown to work.  If I put in 01:00:00 as in 1 hour, and hit start, it starts to count up when it should recognize that there is an entry in the countdown cell and begin counting down instead.

Thank you very much for your work.  I can tell you work hard at what you do and concurrently enjoy helping others.  Thanks again.

B.
Roy CoxGroup Finance Manager

Commented:
I haven't put in a count down yet.

I am confused though about your reference to a cell, do you mean the TextBox on the UserForm?

Author

Commented:
Sorry I was not clear.  What I'm thinking is that the countdown and countup box are the same box.  If the number in the box is -0- or blank, then it counts up.  However, if there is a number such as 01:00:00, then it automatically knows that it is a countdown situation.

Make sense?

B.
Roy CoxGroup Finance Manager

Commented:
If that is the case then the pause button won't work. The time is currently in a Label which prevents entry. I thought to add a TextBox to enter a time in.

Author

Commented:
Let's go with your approach to keep it simple.

Thanks,

B
Professor JMicrosoft Excel Expert
Top Expert 2014

Commented:
Bright01,

i am not sure what are you trying to achieve with this Countdown timer, but there is a very good free Add-in Developed by Tushar Mehta you can have a look and see how it works, maybe that would help.

http://www.tushar-mehta.com/excel/software/vba_timer/

Author

Commented:
Professor Jim,

Did you see Roy's posted WB/WS?

The timer counts Up and counts Down.  I'll take a look at Tushar's work too.

B.
Roy CoxGroup Finance Manager

Commented:
I'll get back to this, I need to get the count down working as required.

Author

Commented:
Are we still working on this or should I close it out?
Roy CoxGroup Finance Manager

Commented:
Sorry, I'm working on it but I've not been too well this last week.

Author

Commented:
No worries.  Just checking.
Roy CoxGroup Finance Manager

Commented:
I've managed to get the count down working as I wanted.

I've added a quick entry for times.

I just need to tidy up the userform and I'll upload a completed file.
Group Finance Manager
Commented:
Sorry about the delay.

This form contains the counter that was in the previous example plus a count down. To make ure that the time is entered in the correct format the code amends the display so entering 000010 will be changed to 00:00:10, i.e. 10 seconds.
EE_Timer-v1.05.xlsm

Author

Commented:
Roy, Thank you so much for sticking with this endeavor.  Well done!  I'll be working on it until I break it which is when I'll author a follow on question.  Again, great job!  You have a lot of tenacity to stick with things until completed.

Best regards,

B.
Roy CoxGroup Finance Manager

Commented:
No problem B. Let me know what you need to do further

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial