Platforms to show: All Mac Windows Linux Cross-Platform
WindowsDirectoryWatcherMBS class
| Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
| class | Folder Change Watching | MBS Win Plugin | 12.0 | ❌ No | ✅ Yes | ❌ No | ❌ No | Desktop, Console & Web |
Create an object, add a few directories you want to watch and wait for changes being reported by NextChange method.
- 4 methods
- method AddDirectory(path as folderitem, Recursive as boolean, Flags as Integer) as Boolean
- method AddDirectory(path as string, Recursive as boolean, Flags as Integer) as Boolean
- method Constructor
- method NextChange as WindowsDirectoryChangeMBS
- 8 constants
Flags
| Constant | Value | Description |
|---|---|---|
| kNotifyChangeAttributes | 4 |
Any attribute change in the watched directory or subtree causes a change notification wait operation to return. |
| kNotifyChangeCreation | 64 |
Any change to the creation time of files in the watched directory or subtree causes a change notification wait operation to return. |
| kNotifyChangeDirName | 2 |
Any directory-name change in the watched directory or subtree causes a change notification wait operation to return. Changes include creating or deleting a directory. |
| kNotifyChangeFilename | 1 |
Any file name change in the watched directory or subtree causes a change notification wait operation to return. Changes include renaming, creating, or deleting a file. |
| kNotifyChangeLastAccess | 32 | Any change to the last access time of files in the watched directory or subtree causes a change notification wait operation to return. more |
| kNotifyChangeLastWrite | 16 |
Any change to the last write-time of files in the watched directory or subtree causes a change notification wait operation to return. The operating system detects a change to the last write-time only when the file is written to the disk. For operating systems that use extensive caching, detection occurs only when the cache is sufficiently flushed. |
| kNotifyChangeSecurity | 256 |
Any security-descriptor change in the watched directory or subtree causes a change notification wait operation to return. |
| kNotifyChangeSize | 8 |
Any file-size change in the watched directory or subtree causes a change notification wait operation to return. The operating system detects a change in file size only when the file is written to the disk. For operating systems that use extensive caching, detection occurs only when the cache is sufficiently flushed. |
This class has no sub classes.
Blog Entries
Xojo Developer Magazine
Some examples using this class:
Some related classes:
The items on this page are in the following plugins: MBS Win Plugin.
WindowsDirectoryChangeMBS - WindowsDiscInfoMBS