WaitForChangedResult.Name Propriedade

Definição

Obtém ou define o nome do arquivo ou diretório que foi alterado.

public:
 property System::String ^ Name { System::String ^ get(); void set(System::String ^ value); };
public string? Name { get; set; }
public string Name { get; set; }
member this.Name : string with get, set
Public Property Name As String

Valor da propriedade

String

O nome do arquivo ou diretório que foi alterado.

Exemplos

O exemplo a seguir demonstra a Name propriedade. Este exemplo de código faz parte de um exemplo maior fornecido para a WaitForChangedResult estrutura.

' Suspend the calling thread until the file has been deleted.
Dim cr As IO.WaitForChangedResult = fsw.WaitForChanged(WatcherChangeTypes.Deleted)

' Tell the user the file is deleted and exit.
Console.WriteLine("The {0} files is deleted; program is exiting", cr.Name)

Aplica-se a