Replaced Console.WriteLine with Trace.WriteLine