EventLogInformation.Attributes Vlastnost

Definice

Získá atributy souboru protokolu přidruženého k protokolu.

public:
 property Nullable<int> Attributes { Nullable<int> get(); };
public int? Attributes { get; }
member this.Attributes : Nullable<int>
Public ReadOnly Property Attributes As Nullable(Of Integer)

Hodnota vlastnosti

Vrátí celočíselnou hodnotu. Tato hodnota může mít hodnotu null.

Poznámky

Hodnoty této vlastnosti jsou stejné jako FileAttributes hodnoty typu. Chcete-li usnadnit práci s touto vlastností, můžete hodnotu převést na tento typ pomocí následujícího kódu:

using System.Diagnostics.Eventing.Reader;
using System.IO;

EventLogInformation eventLogInformation;
FileAttributes? fileAttributes = (FileAttributes?)eventLogInformation.Attributes;
Imports System.Diagnostics.Eventing.Reader
Imports System.IO

Dim eventLogInformation As EventLogInformation
Dim fileAttributes = CType(eventLogInformation.Attributes, FileAttributes?)

Platí pro