Countdown slider

Here it is.

Thank you very much again, Anke. Best regards,

Joaquín.-

MIT_AI_2.aia (5.0 KB)

Until now, the Slider is always divided into 100 positions, this produces those jumps.

We hope this changes in future updates.

Try this code
1234s

Instead of using Slider, you can use Canvas like in this example from @TIMAI2

1 Like

Thank you so much, Juan Antonio, for you help, I'll try it.

Recibe un cordial saludo,

Joaquín. -

Here a simpler method, using a label instead of a slider:

image

labelCountdown.aia (3.6 KB)

1 Like

Here you go:
MIT_AI_2b.aia (73.8 KB)

Screenshot

grafik

Theme: Device Default

You might want to switch to Theme "Device Default":

grafik

grafik

3 Likes

That's why I posted the above link in post #2.

Good idea @TIMAI2 !

We can also use several HorizontalArrangements with a background image.
deslizaimagen4

bor_slider_automatic.aia (10.9 KB)

1 Like

But in your case the Label.Width (instead of Slider) only changes every 20 sec and not continuously, as with my approach (using a Slider).

Blocks

Btw, the same applies for @Juan_Antonio's approach.

every second

Admittedly, for longer durations, I could have used more mathematics to evidence a movement on each tick of the clock.

Juan Antonio, I'm doing something wrong, it doesn't work for me. :thinking:

I'll insist.

Thank you so much for your help,

Un saludo,

Joaquín.-

What code are you using? Upload your .aia

I don't think that the behavior of the width of the label (e.g. for 30 minutes, what the user wants) can be mathematically circumvented. But I like to be surprised.

Did you try my aia (→ MIT_AI_2b.aia (73.8 KB)?
If so, does it work for you the way you wanted?

In my opinion, the author of the post wants a uniform, smooth movement, so the clock speed must be as low as possible. The slider method won't really work here because the slider accuracy is low, as @Juan_Antonio mentioned. The slider will not have smooth motion, only jumps as seen in the @Anke app.
It's a good idea to use an arrangement or any other component and play with its width. Here is an example of a progress bar made with an arrange. Its accuracy is not based on the timing of the clock component, which we know is not very accurate. I achieved fluency and accuracy by reading the current state of the milis counter.

progres.aia (3.6 KB)

1 Like

The same applies to your approach, with the small difference that here the jumps are shorter (at 30 min there are 5 sec intervals / jumps). However, smooth is different.

Yes, in the case of 30 minutes and the slider, the movement of the strip can be seen every 18 seconds, in the case of using a different component, every 4.5 seconds.
The vertical width of my screen is about 400px. If the app was operated horizontally, the smoothness of the bar would increase, while in the case of the slider it is always 100 points.

1 Like

Good evening, all.

Firstly, my apologies because I am delaying my answers but, believe me, today was not an easy day for me.

Now, I'm going to do it one by one and, furthermore, I want to say all of you thanks for your advises because I have learned with you in a few hours more than I have learned in a month by myself.

All the best for all of you,

Joaquín.-

Fixed! Thanks, Juan Antonio.

Well, I tested your code and I can say that it works so fine, but it is not exactly what I'm looking for. However, I will keep it in mind for the future.

Thank you very much again. Recibe un muy cordial saludo,

Joaquín.-

Hellow, Anke.

I've tested your example right now, today was a hard day for me.

Well, it's fantastic, it's almost what I want, the jumps have regularity and they are almost invisibles when time is increased.

I want to thank you for the time you have spent with me and tell you that I have learned a lot from the examples you have given me.

Best regards,

Joaquín.-

Right! This is exactly what I want, but with the slider functionality too. Sadly, I saw that's not possible, what a shame!

Thank you very much for your time, I've learned very interesting things with you.

Best regards,

Joaquín.-