DebugView

This post has been moved to http://blog.cumps.be/using-debugview-and-c/ where you can find more information. 

Archived version below
----------------------------- 

Another very nice tool was DebugView. This is a tool from Sysinternals that enables you to monitor all debug messages on your system. This allows you to have the following in your code:

 

Debug.Write("This is written trough System.Diagnostics.Debug.Write.");

Trace.Write("This is written trough System.Diagnostics.Trace.Write.");

 

Debug.WriteIf(inDebug, "This is written because inDebug is true.");      


Having this in your code is very handy for debugging in an early stage, where you haven’t added a logging component, such as Enterprise Library, yet. Or in a scenario where you don’t want to attach the Visual Studio Debugger, or can’t attach it, but still want to view some debug information from your program.

It’s also possible to connect to a remote computer, and intercept these debug messages remotely



After having added code like this, the only thing that has to be done is open DebugView and run the program. DebugView would then intercept the messages and display them as following:



This tool is only 240 KB in size, and completely free, which is really amazing for such a powerful and useful tool.

1 Comment

Comments have been disabled for this content.