How do you debug web applications written in C# in Visual Studio? I'm using Console.WriteLine expecting the text to appear in the Output tab. Like it does when you develop console applications. But for web applications, the开发者_如何学运维 console output doesn't show up anywhere.
Debug.WriteLine
They are two form to write in Console Output for NET applications.
Debug.WriteLine() // See [Microsoft Documentation][1]
Trace.WriteLine() // See [Microsoft][2] documentation for more information
The difference between the two is that Debug only work when the program is in DEBUG mode. In the other hand TRACE works always. You can also set different levels of TRACE. See documentation for more information.
I hope that this information help you.
精彩评论