Component: DirectoryWatcher 
----------------------------

Watch directories for changes on Windows.

Watch changes on directories and get script triggered for changes.  
See [FSEvents](component_FSEvents.md) functions for Mac.

| Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|
| [7.1](newinversion71.md "First functions introduced with version 7.1.") / [12.4](newinversion124.md "Newest functions in version 12.4.") | ❌ No | ✅ Yes | ❌ No | 🔶 54%, on Windows | ❌ No |

  
| Item | Details | Server |
|:--|:--|:--|
| [DirectoryWatcher.AddDirectory](DirectoryWatcherAddDirectory.md)   Adds a directory to watch. | Win only   7.1 | ✅ Server |
| [DirectoryWatcher.ChangeCount](DirectoryWatcherChangeCount.md)   Queries the change count. | Win only   7.1 | ✅ Server |
| [DirectoryWatcher.Create](DirectoryWatcherCreate.md)   Creates a new directory watcher. | Win only   7.1 | ✅ Server |
| [DirectoryWatcher.GetEvaluate](DirectoryWatcherGetEvaluate.md)   Queries the expression to evaluate. | Win only   7.1 | ❌ Server |
| [DirectoryWatcher.GetFileName](DirectoryWatcherGetFileName.md)   Returns the file name for the watcher. | Win only   7.1 | ❌ Server |
| [DirectoryWatcher.GetScriptName](DirectoryWatcherGetScriptName.md)   Returns the script name for the watcher. | Win only   7.1 | ❌ Server |
| [DirectoryWatcher.NextChange](DirectoryWatcherNextChange.md)   Queries next change in queue. | Win only   7.1 | ✅ Server |
| [DirectoryWatcher.Release](DirectoryWatcherRelease.md)   Releases directory watcher. | Win only   7.1 | ✅ Server |
| [DirectoryWatcher.ReleaseAll](DirectoryWatcherReleaseAll.md)   Releases all directory watchers. | Win only   7.4 | ✅ Server |
| [DirectoryWatcher.SetEvaluate](DirectoryWatcherSetEvaluate.md)   Sets the expression to evaluate. | Win only   7.1 | ❌ Server |
| [DirectoryWatcher.SetFileName](DirectoryWatcherSetFileName.md)   Sets the file name for watcher. | Win only   7.1 | ❌ Server |
| [DirectoryWatcher.SetScriptName](DirectoryWatcherSetScriptName.md)   Sets the script name for watcher. | Win only   7.1 | ❌ Server |
| [DirectoryWatcher.TotalChangeCount](DirectoryWatcherTotalChangeCount.md)   Queries the total number of changes seen. | Win only   12.4 | ✅ Server |

13 functions shown.

These functions require a license (54%).

### Release notes

- **Version 12.4**
    - Added [DirectoryWatcher.TotalChangeCount](https://www.mbsplugins.eu/DirectoryWatcherTotalChangeCount.shtml) function.
- **Version 7.4**
    - Added [DirectoryWatcher.ReleaseAll](http://www.mbsplugins.eu/DirectoryWatcherReleaseAll.shtml).
- **Version 7.1**
    - Added [DirectoryWatcher](http://www.mbsplugins.eu/component_DirectoryWatcher.shtml) functions for Windows.

### Blog Entries

- [MBS FileMaker Plugin 12.4](https://www.mbsplugins.de/archive/2022-09-27/MBS_FileMaker_Plugin_124/monkeybreadsoftware_blog_filemaker)
- [Neues MBS Plugin 12.4 für Claris FileMaker](https://www.mbsplugins.de/archive/2022-09-06/Neues_MBS_Plugin_124_für_Clar/monkeybreadsoftware_blog_filemaker)
- [MBS Plugin 12.4 for Claris FileMaker](https://www.mbsplugins.de/archive/2022-09-06/MBS_Plugin_124_for_Claris_File/monkeybreadsoftware_blog_filemaker)
- [Combine MBS functions to automate processes in FileMaker](https://www.mbsplugins.de/archive/2019-04-11/Combine_MBS_functions_to_autom/monkeybreadsoftware_blog_filemaker)
- [5000 Functions in MBS Plugin](https://www.mbsplugins.de/archive/2017-11-11/5000_Functions_in_MBS_Plugin/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin 7.1 - Über 4400 Funktionen in einem Plugin](https://www.mbsplugins.de/archive/2017-03-14/MBS_FileMaker_Plugin_71_-_Übe/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin 7.1 - More than 4400 Functions In One Plugin](https://www.mbsplugins.de/archive/2017-03-14/MBS_FileMaker_Plugin_71_-_More/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin, version 7.1pr4](https://www.mbsplugins.de/archive/2017-03-06/MBS_FileMaker_Plugin_version_7/monkeybreadsoftware_blog_filemaker)

### Example Databases

- [Win Only/Directory Watcher](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Win%20Only/Directory%20Watcher.shtml#2ScriptAnchor_)

[HTML Version](component_DirectoryWatcher.shtml)