Export (0) Print
Expand All

FileSystemWatcher.OnChanged Method

Raises the Changed event.

[Visual Basic]
Protected Sub OnChanged( _
   ByVal e As FileSystemEventArgs _
)
[C#]
protected void OnChanged(
 FileSystemEventArgs e
);
[C++]
protected: void OnChanged(
 FileSystemEventArgs* e
);
[JScript]
protected function OnChanged(
   e : FileSystemEventArgs
);

Parameters

e
A FileSystemEventArgs that contains the event data.

Remarks

OnChanged is called when changes are made to the size, system attributes, last write time, last access time, or security permissions of a file or directory in the directory being monitored.

Use the NotifyFilter property to restrict the number of events raised when the Changed event is handled.

Raising an event invokes the event handler through a delegate. For more information, see Raising an Event.

Notes to Inheritors:  When overriding OnChanged in a derived class, be sure to call the base class's OnChanged method.

Requirements

Platforms: Windows NT Server 4.0, Windows NT Workstation 4.0, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

FileSystemWatcher Class | FileSystemWatcher Members | System.IO Namespace | Changed | NotifyFilter | FileSystemEventArgs | FileSystemEventHandler

Show:
© 2014 Microsoft