# Gateway Scheduled Script change hour

**URL:** <https://forum.inductiveautomation.com/t/gateway-scheduled-script-change-hour/73751>\
**Category:** Ignition\
**Tags:** perspective, ignition81, ignition80\
**Created:** [May 15, 2023, 10:20pm UTC](https://forum.inductiveautomation.com/t/gateway-scheduled-script-change-hour/73751 "2023-05-15T22:20:34Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sancklerck](https://avatars.discourse-cdn.com/v4/letter/s/7feea3/32.png) [@Sancklerck](https://forum.inductiveautomation.com/u/Sancklerck)\
**Post date:** [May 15, 2023, 10:20pm UTC](https://forum.inductiveautomation.com/t/gateway-scheduled-script-change-hour/73751/1 "2023-05-15T22:20:34Z")

</div>

Hello, i have a Gateway Scheduled Scripts that runs every day at 2:00pm, the problem is that this Script could fail, in that case, i would like to change the time of the Script so it could run again 15 minutes later, but only if the first one failed, is this possible?

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [May 15, 2023, 10:28pm UTC](https://forum.inductiveautomation.com/t/gateway-scheduled-script-change-hour/73751/2 "2023-05-15T22:28:00Z")

</div>

How about,

- Create a memory tag of type Date.
- Schedule the script to run at 14:00 and 14:15.
- Have your script update the tag with the current timestamp on successful completion of the script.
- At the start of the script check the memory tag and exit the script if the timestamp is less than 16 minutes ago.
