Skip to content

Modern Fs FileWatcher IsWatching

Paul Squires edited this page Oct 19, 2026 · 5 revisions

Home › Filesystem › Filesystem Library › FileWatcher.IsWatching

FileWatcher.IsWatching

Returns true while the watcher is running.

Syntax

FileWatcher.IsWatching( )

Examples

#import "std/fs"
using fs

dim td as FsResultUStr = CreateTempDir( "fbdoc" )
dim as ustring dir_ = td.Value( )
dim as ustring p = PathJoin( dir_, "f.txt" )
WriteAllText( p, "hello" )

dim w as FileWatcher
print w.IsWatching( )        '' false

w.Start( dir_ )
print w.IsWatching( )        '' true

w.Stop( )
print w.IsWatching( )        '' false

RemoveDirAll( dir_ )

Library: Filesystem Library
Category: Filesystem
Documented under: Locking, Mapping And Watching

Clone this wiki locally