Trace.WriteLine : Trace « Development Class « C# / C Sharp






Trace.WriteLine

  



using System;
using System.Data;
using System.Data.SqlClient;
using System.Threading;
using System.Diagnostics;
class MainClass {

    static void Main() {
        Trace.WriteLine("Entered Main()");

        for (int i = 0; i < 6; i++)
            Trace.WriteLine(i);

        Trace.WriteLine("Exiting from Main()");
    }
}

   
  








Related examples in the same category

1.Use Trace.Fail to alert a fail
2.demonstrates post-deployment tracingdemonstrates post-deployment tracing
3.demonstrates the use of TraceListener objectsdemonstrates the use of TraceListener objects
4.Design By Contract Checks.