FileSystemEventArgs.FullPath 属性
获取受影响的文件或目录的完全限定的路径。
**命名空间:**System.IO
**程序集:**System(在 system.dll 中)
语法
声明
Public ReadOnly Property FullPath As String
用法
Dim instance As FileSystemEventArgs
Dim value As String
value = instance.FullPath
public string FullPath { get; }
public:
property String^ FullPath {
String^ get ();
}
/** @property */
public String get_FullPath ()
public function get FullPath () : String
属性值
受影响的文件或目录的路径。
示例
下面的示例阐释了 FullPath 属性。此代码示例摘自一个为 FileSystemEventArgs 类提供的更大的示例。
' This method is called when a file is created, changed, or deleted.
Private Sub OnChanged(ByVal source As Object, ByVal e As FileSystemEventArgs)
' Show that a file has been created, changed, or deleted.
Dim wct As WatcherChangeTypes = e.ChangeType
Console.WriteLine("File {0} {1}", e.FullPath, wct.ToString())
End Sub
.NET Framework 安全性
- FileIOPermission 用于读取文件。关联的枚举:FileIOPermissionAccess.Read
平台
Windows 98、Windows 2000 SP4、Windows Server 2003、Windows XP Media Center Edition、Windows XP Professional x64 Edition、Windows XP SP2、Windows XP Starter Edition
.NET Framework 并不是对每个平台的所有版本都提供支持。有关受支持版本的列表,请参见系统要求。
版本信息
.NET Framework
受以下版本支持:2.0、1.1、1.0