Trace.Unindent Yöntem

Tanım

Geçerli olanı IndentLevel bir azaltır.

public:
 static void Unindent();
[System.Diagnostics.Conditional("TRACE")]
public static void Unindent ();
[<System.Diagnostics.Conditional("TRACE")>]
static member Unindent : unit -> unit
Public Shared Sub Unindent ()
Öznitelikler

Örnekler

Aşağıdaki örnek, girinti düzeyini artırır ve azaltıp izleme iletilerini yayar.

Trace::WriteLine( "List of errors:" );
Trace::Indent();
Trace::WriteLine( "Error 1: File not found" );
Trace::WriteLine( "Error 2: Directory not found" );
Trace::Unindent();
Trace::WriteLine( "End of list of errors" );
Trace.WriteLine("List of errors:");
Trace.Indent();
Trace.WriteLine("Error 1: File not found");
Trace.WriteLine("Error 2: Directory not found");
Trace.Unindent();
Trace.WriteLine("End of list of errors");
Trace.WriteLine("List of errors:")
Trace.Indent()
Trace.WriteLine("Error 1: File not found")
Trace.WriteLine("Error 2: Directory not found")
Trace.Unindent()
Trace.WriteLine("End of list of errors")

Bu örnek aşağıdaki çıkışı oluşturur:

List of errors:  
     Error 1: File not found  
     Error 2: Directory not found  
End of list of errors  

Şunlara uygulanır

Ayrıca bkz.