# Gateway Script to monitor directory for new files

**URL:** <https://forum.inductiveautomation.com/t/gateway-script-to-monitor-directory-for-new-files/16124>\
**Category:** Ignition\
**Created:** [November 26, 2017, 11:02pm UTC](https://forum.inductiveautomation.com/t/gateway-script-to-monitor-directory-for-new-files/16124 "2017-11-26T23:02:32Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![Jenko](https://avatars.discourse-cdn.com/v4/letter/j/2acd7d/32.png) [@Jenko](https://forum.inductiveautomation.com/u/Jenko)\
**Post date:** [November 29, 2017, 11:50pm UTC](https://forum.inductiveautomation.com/t/gateway-script-to-monitor-directory-for-new-files/16124/5 "2017-11-29T23:50:27Z")

</div>

Thanks JordanCClark and PerryAJ, that simple code is exactly what I needed.

Works perfectly, at this stage I’m happy to poll through a timed script and keep it simple. Thanks for the advice regarding WatchService though - I might have another use for that elsewhere in my project.

Cheers  
Dan

---

_[View the full topic](https://forum.inductiveautomation.com/t/gateway-script-to-monitor-directory-for-new-files/16124)._
