I can not get Debug or Trace to work in Visual Studio 2010 C# Express. I have “Redirect all output to immediate window” – Unchecked. Nothing is going to output window.
using System.Diagnostics;
Trace.Write("Hello World");
Trace.WriteLine("Hello World");
Debug.Write("Hello World2");
Debug.WriteLine("Hello World2");
Make sure that both checkboxes “Define DEBUG constant” and “Define TRACE constant” in project properties on page Build are checked.