TraceSection.Enabled Proprietà

Definizione

Ottiene o imposta un valore che indica se è attivato il servizio di traccia di ASP.NET.

public:
 property bool Enabled { bool get(); void set(bool value); };
[System.Configuration.ConfigurationProperty("enabled", DefaultValue=false)]
public bool Enabled { get; set; }
[<System.Configuration.ConfigurationProperty("enabled", DefaultValue=false)>]
member this.Enabled : bool with get, set
Public Property Enabled As Boolean

Valore della proprietà

true se la traccia è attivata; in caso contrario, false. Il valore predefinito è true.

Attributi

Esempio

Nell'esempio di codice riportato di seguito viene illustrato come utilizzare la proprietà Enabled. Questo esempio di codice fa parte di un esempio più ampio fornito per la TraceSection classe .


// Get the current Enabled property value.
Boolean enabledValue = traceSection.Enabled;

// Set the Enabled property to false.
traceSection.Enabled = false;

' Get the current Enabled property value.
Dim enabledValue As Boolean = traceSection.Enabled

' Set the Enabled property to false.
traceSection.Enabled = False

Si applica a

Vedi anche