NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

FileSystemWatcher.IncludeSubdirectories

Gets or sets a value indicating whether subdirectories within the specified path should be monitored.

[Visual Basic]
Overridable Public Property IncludeSubdirectories As Boolean
[C#]
public bool IncludeSubdirectories {virtual get; virtual set;}
[C++]
public: __property virtual bool get_IncludeSubdirectories();
public: __property virtual void set_IncludeSubdirectories(bool);
[JScript]
public function get IncludeSubdirectories() : Boolean;
public function set IncludeSubdirectories(Boolean);

Property Value

true if you want to monitor subdirectories; otherwise, false. The default is false.

Remarks

Use the IncludeSubdirectories property when you want to watch for change notifications for files and directories contained within subdirectories of the Path property. This is one way to filter out unwanted notifications. For more information on filtering out unwanted notifications, see the ChangedFilter, Filter, InternalBufferSize, and Target properties.

When true, IncludeSubdirectories is recursive through the entire sub-tree, not just the child directories. The relative path to a file or directory within the sub-tree is returned in the Name property of FileSystemEventArgs and the OldName property of RenamedEventArgs, depending on the changes you are watching for. You can get the fully qualified path from the FullPath property of FileSystemEventArgs and the OldFullPath property of RenamedEventArgs, depending on the changes you are watching for.

See Also

FileSystemWatcher Class | FileSystemWatcher Members | System.IO Namespace | ChangedFilter | FileSystemEventArgs | Filter | TBD | TBD | InternalBufferSize | TBD | TBD | Path | RenamedEventArgs | Target