# Reset Param After 10 mins

**URL:** <https://forum.inductiveautomation.com/t/reset-param-after-10-mins/103188>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [March 4, 2025, 6:32am UTC](https://forum.inductiveautomation.com/t/reset-param-after-10-mins/103188 "2025-03-04T06:32:58Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![scadafan](https://avatars.discourse-cdn.com/v4/letter/s/90db22/32.png) [@scadafan](https://forum.inductiveautomation.com/u/scadafan)\
**Post date:** [March 4, 2025, 6:32am UTC](https://forum.inductiveautomation.com/t/reset-param-after-10-mins/103188/1 "2025-03-04T06:32:58Z")

</div>

Simple question but breaking my head over it.

I have a page that toggles a bit to view a value. Basically changes the visibility on a label when I click a button. How could I have it change this value back from true to false after 10 mins. Hoping that makes sense

---

<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:** [March 4, 2025, 9:09am UTC](https://forum.inductiveautomation.com/t/reset-param-after-10-mins/103188/2 "2025-03-04T09:09:53Z")

</div>

On the view's CUSTOM properties create an object as shown:

 ![Visibility timer](https://us1.discourse-cdn.com/inductiveautomation/original/3X/4/d/4d6e9e9e2597ac08dc150cb64960767b0f8b4897.png)

- On `setTime` create an expression binding `now(0)`. This will fire once when the application loads.
- On `visibility` create an expression binding,  
`!(now(1000) - {view.custom.visibilityTimer.setTime} > 10000)`  
(Note the `!` at the start.) This will turn `false` when more than 10 s has passed since the time was set.
- On the button create an `onActionPerformed` event script:

```python
def runAction(self, event):
	self.view.custom.visibilityTimer.setTime = system.date.now()

```

This will write the time of button press into the `setTime` property.

**Improvements**

1. You could also bind the button's enabled property to the `visibility` property to prevent a second press while it's timing out, if desired.
2. Make a session variable to hold the time delay value and reference that in the visibiliy binding. That way you can change the delay for everywhere you use it in one place without editing expressions.

Just watch the label to see if it shows up for 10 s when the view is first loaded. You might not want that.

---

<div class="post-metadata">

**Author:** ![scadafan](https://avatars.discourse-cdn.com/v4/letter/s/90db22/32.png) [@scadafan](https://forum.inductiveautomation.com/u/scadafan)\
**Post date:** [March 4, 2025, 3:41pm UTC](https://forum.inductiveautomation.com/t/reset-param-after-10-mins/103188/3 "2025-03-04T15:41:39Z")

</div>

oh wow thank you this is exactly what I need. Thank you very much
