# Action and delay

**URL:** <https://community.homey.app/t/action-and-delay/73343>\
**Category:** Questions & Help\
**Created:** [December 9, 2022, 3:00pm UTC](https://community.homey.app/t/action-and-delay/73343 "2022-12-09T15:00:45Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Matthieu\_Moreau](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/matthieu_moreau/32/57526_2.png) [@Matthieu\_Moreau](https://community.homey.app/u/Matthieu_Moreau)\
**Post date:** [December 9, 2022, 3:00pm UTC](https://community.homey.app/t/action-and-delay/73343/1 "2022-12-09T15:00:45Z")

</div>

Good morning all,

how to have a condition with a delay in between.

example :

if gate is open and entrance door open within 5 minutes then…

thank you

---

<div class="post-metadata">

**Author:** ![Marcel\_Ubels](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/marcel_ubels/32/18860_2.png) [@Marcel\_Ubels](https://community.homey.app/u/Marcel_Ubels)\
**Post date:** [December 9, 2022, 3:14pm UTC](https://community.homey.app/t/action-and-delay/73343/2 "2022-12-09T15:14:17Z")

</div>

When gate goes open THEN start timer 5 min  
When entrance door goes open, AND gate is open, THEN start timer 5 min  
If timer is 0, AND entrance door is open AND gate is open, THEN close gate
