Cool tracing with Visual Studio
Because we are preparing Beta2 of Orcas, I started spending more and more time with the debugger and with tracing enabled in our OM (vide: https://blogs.msdn.com/michalma/archive/2006/12/08/tracing-in-tfs-msscci-provider.aspx). As we all know there are 2 listeners we usually use - file listeners, that dumps everything into file and perf listener that pops up cool dialog, but lacks details. You can imagine my surprise when I discovered that just by attaching the debugger to the running app, we add yet another listener - one that dumps everything into Output Window in VS. It's very cool, because while stepping through the code we can immediately see what kind of server calls where made. At first I wasn't sure if this is not some kind of magic Buck put into our OM. But no - even in the simplest application, when you put
Trace.TraceInformation("Hola Mundo!");
it will be written in the Output Window. Cool :)
Comments
- Anonymous
May 29, 2007
Not just visual studio - any debugger that knows about the OutputDebugString api will do - you can even throw together your own app to capture trace messages from a running application as per this article: http://www.codeproject.com/vb/net/VisualTraceListener.asp