# Auto - Close Error Box

**URL:** <https://forum.inductiveautomation.com/t/auto-close-error-box/12786>\
**Category:** General Discussion\
**Created:** [March 14, 2017, 5:31pm UTC](https://forum.inductiveautomation.com/t/auto-close-error-box/12786 "2017-03-14T17:31:45Z")\
**Posts on this page:** 1\
**Showing post:** 19

<div class="post-metadata">

**Author:** ![dkhayes117](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/dkhayes117/32/68344_2.png) [@dkhayes117](https://forum.inductiveautomation.com/u/dkhayes117)\
**Post date:** [September 9, 2020, 4:42pm UTC](https://forum.inductiveautomation.com/t/auto-close-error-box/12786/19 "2020-09-09T16:42:00Z")

</div>

I used a popup window to display any messages. The popup window has an “openTime” parameter. Then I have an expression to monitor time the message has been open

```auto
minutesBetween({Root Container.openTime},now())

```

If minutesBetween \>= 5 then

```auto
system.nav.closeParentWindow()

```

---

_[View the full topic](https://forum.inductiveautomation.com/t/auto-close-error-box/12786)._
