How to create a countdown timer

Hello. I am a beginner with Glide. I am creating a mobile app on the free plan.

I would like to display a 2-minute countdown timer on the screen.
If anyone knows a free and easy way to do this, please let me know.

Thank you for your attention.

Is there a way to do it for free?
Also, I would like the countdown timer to be stopped or reset every time the button is pressed.

Does it need to count down every second?

It is possible to do something with Glide date math, but because Glide only updates the time every 10 seconds, you would only see the timer change once every 10 seconds.

Would that be acceptable?

3 Likes

It’s fine.
Could you please provide more details?

Create 3 columns as follows:

  • A User Specific Date/Time column (call this “Timer End”)
  • A math column to calculate the time 2 minutes into the future: Now + 2/1440
  • A math column to calculate the “Time Remaining”: Timer End - Now

To start the timer, use a button with a Set Column Values action that takes the value of the 2nd column (Now + 2 mins) and writes it into the 1st column (Timer End).

To display the count down, use a text component and point it at the Time Remaining column.

To reset, clear the value in the User Specific column.

3 Likes

Here’s a working timer with some imperfection.
CD Timer

Data


Math

Feel free to clarify.

Some other related topics:

2 Likes

Thank you for your response. I couldn’t understand the following part no matter how hard I tried. Could you please explain it in more detail?
What specific settings do I need to configure?

To start the timer, use a button with a Set Column Values action that takes the value of the 2nd column (Now + 2 mins) and writes it into the 1st column (Timer End).

CleanShot 2023-05-23 at 13.32.18@2x

2 Likes

Thank you for your assistance, @Darren_Murphy. Thanks to you, it worked out well.

And, @Trustin Could you please provide more details and perhaps use screenshots to explain?
How should I configure each column, such as “Show Corrected Time” in the data editing screen?

I am using an unorthodox method haha. But having trouble getting the right time to display.
If I enter 60 seconds and hit start, it shows 1:04. But if I entered 120, the time will show 2:24.
That’s why i use [corrected time] to do some “correction” but it’s not working correctly lol.
Here’s a template for you to play with.
image

Or am i overcomplicating things.

1 Like

Or use the Magic! :upside_down_face:

Hey Uzo love you enthusiasm and magic!
But for me or some user, we are #FreeGliders learning on free plan or even trying to work within constraints and limitations as this allows room for creativity.
CSS can do amazing stuff but I would like to see how far we can stretch Glide without css!

Glide on!

1 Like

This is a free App, and I’m a master of stretching the limits :wink:

2 Likes

Is this one better?.. no CSS… 2 minutes as you requested…

Free :stuck_out_tongue_winking_eye: App.

@kokoro_koto, what do you think?

3 Likes

Hi Uzu, could you please share the CSS to hide the HOURS? Thank you.
I need to show only the minutes and seconds.