TCnFileSystemWatcher.WaitForChanged(TWatcherChangeTypes_Set,Integer) Method

A synchronous method that returns a structure that contains specific information on the change that occurred, given the type of change you want to monitor and the time (in milliseconds) to wait before timing out.

Namespace: CNClrLib.Component.FileSystemWatcher
public
 function WaitForChanged(ChangeType: TWatcherChangeTypes_Set; Timeout: Integer): _WaitForChangedResult; overload;

Parameters

ChangeType
Type: System.Void

The CNClrLib.Control.EnumTypes.TWatcherChangeTypes_Set to watch for.

Timeout
Type: Integer

The time (in milliseconds) to wait before timing out.

Return Value

Type: _WaitForChangedResult

A WaitForChangedResult that contains specific information on the change that occurred.

Note
This method allows an event handler to be invoked to respond to file changes even if the EnableRaisingEvents property is set to false.