# I don't want the countdown to be reset when changing the screen, what to do?

**URL:** https://forum.adalo.com/t/i-dont-want-the-countdown-to-be-reset-when-changing-the-screen-what-to-do/18354
**Category:** Get Help
**Created:** [October 12, 2021, 5:30am UTC](https://forum.adalo.com/t/i-dont-want-the-countdown-to-be-reset-when-changing-the-screen-what-to-do/18354 "2021-10-12T05:30:32Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Elbordo](https://avatars.discourse-cdn.com/v4/letter/e/7cd45c/32.png) [@Elbordo](https://forum.adalo.com/u/Elbordo)
#### Post date: [October 12, 2021, 5:30am UTC](https://forum.adalo.com/t/i-dont-want-the-countdown-to-be-reset-when-changing-the-screen-what-to-do/18354/1 "2021-10-12T05:30:32Z")

</div>

create posts with a countdown, and when the account is finished, delete the post. so I try to do it and every time I change the window the countdown resets, and I want it to continue without resetting again

---

<div class="post-metadata">

### Author: ![Yongki](https://avatars.discourse-cdn.com/v4/letter/y/7c8e57/32.png) [@Yongki](https://forum.adalo.com/u/Yongki)
#### Post date: [October 12, 2021, 6:13am UTC](https://forum.adalo.com/t/i-dont-want-the-countdown-to-be-reset-when-changing-the-screen-what-to-do/18354/2 "2021-10-12T06:13:34Z")

</div>

Hi @Elbordo ,

I think this component is interesting for you,

> **[Countdown for Adalo | NoCode Monkey](https://www.nocodemonkey.io/components/countdown)**
>
> Use the Countdown to enhance your app. Features include...• Countdown # of Seconds or to a date • Pause timer via toggle • Save remaining time to database - Track time across screens • Display remaining Days, Hours, Minutes, and Seconds

And another alternative, if I may suggest, you can add additional property for expiration date, and use them with countdown too, but 0 seconds, and action to delete whenever the expiration date pass current time. Put this at entry screen and view screen, so expired post will not be seen.

---

<div class="post-metadata">

### Author: ![Elbordo](https://avatars.discourse-cdn.com/v4/letter/e/7cd45c/32.png) [@Elbordo](https://forum.adalo.com/u/Elbordo)
#### Post date: [October 12, 2021, 1:36pm UTC](https://forum.adalo.com/t/i-dont-want-the-countdown-to-be-reset-when-changing-the-screen-what-to-do/18354/3 "2021-10-12T13:36:26Z")

</div>

Hello Yongki, how would the second alternative be? Could you help me a little.

---

<div class="post-metadata">

### Author: ![Yongki](https://avatars.discourse-cdn.com/v4/letter/y/7c8e57/32.png) [@Yongki](https://forum.adalo.com/u/Yongki)
#### Post date: [October 12, 2021, 7:30pm UTC](https://forum.adalo.com/t/i-dont-want-the-countdown-to-be-reset-when-changing-the-screen-what-to-do/18354/4 "2021-10-12T19:30:06Z")

</div>

> [@Yongki](#):
>
> you can add additional property for expiration date, and use them with countdown too, but 0 seconds, and action to delete whenever the expiration date pass current time. Put this at entry screen and view screen, so expired post will not be seen.

Try this first and let me know the result.

---

<div class="post-metadata">

### Author: ![Victor](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/victor/32/2054_2.png) [@Victor](https://forum.adalo.com/u/Victor)
#### Post date: [October 14, 2021, 9:40am UTC](https://forum.adalo.com/t/i-dont-want-the-countdown-to-be-reset-when-changing-the-screen-what-to-do/18354/5 "2021-10-14T09:40:22Z")

</div>

Hi @Elbordo,

Let me expand reply by @Yongki a bit.

If your **post** needs to disappear after some time - you can set an expiration date for a **post** , and use it for future actions. For example:

- add a DateTime property to Posts collection, call it ExpirationTime
- upon creating a post, set this property to CurrentTime+0.5 (this will mean that the post will exist for 12 hours)
- use an expression: (Current Post-\>ExpirationTime - CurrentTime)\*86400 in Countdown timer component (number to count down from).
- result: each time you will enter this screen, countdown will start counting based on number of seconds left before expiration
- you will also need to expire the post itself. For this, add a on-screen-enter action to “expire” the post (mark expired, delete is not a very good idea). Make this action conditional, so it happens only when Current Post → Expiration date is before Current Time.

Best regards, Victor.

---

<div class="post-metadata">

### Author: ![system](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/system/32/40401_2.png) [@system](https://forum.adalo.com/u/system)
#### Post date: [October 24, 2021, 9:41am UTC](https://forum.adalo.com/t/i-dont-want-the-countdown-to-be-reset-when-changing-the-screen-what-to-do/18354/6 "2021-10-24T09:41:11Z")

</div>

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.
