Debug Output | CodeGuru

Debug Output

This program is showing all debug information when your program is running, not in the Debug output window of your compiler, but in an other window. The reason for DbgOut doesn’t use OutputDebugString is to show always debug string in an other window (like in the old day Win 3.1). You can save, modify or […]

Written By
CodeGuru Staff
CodeGuru Staff
Aug 6, 1998
1 minute read
CodeGuru content and product recommendations are editorially independent. We may make money when you click on links to our partners. Learn More

This program is showing all debug information when your
program is running, not in the Debug output window of your
compiler, but in an other window.
The reason for DbgOut doesn’t use OutputDebugString is to show
always debug string in an other window (like in the old day Win
3.1).

You can save, modify or print this information (DbgOut.exe is
using an EditView from MFC)

Main macro
DBGOUT : show a formatting string
DBGOUT_LASTERROR : Show last error message in an human way

The main difference with Message Tacer is there are no lib to
link. Only include DbgOut.h and voil`.
You can see every OutputDebugString of processes not attach to a
debugger, or string send by DBGOUT macro.

Program option

  • Always on top
  • show all OutputDebugString with the pid of the process
    who send it

You could find in this program :

  • a way to run a single instance under NT.
  • managing UNICODE and ANSI string
  • an example of using WM_COPYDATA as IPC
#include <DbgOut.h>
.....
    int foo = 66;
    DBGOUT (_T("Something to say (%d)"), foo);
.....
    if ( ! m_file.Open (pPath, CFile::modeRead | CFile::shareDenyWrite, &m_fileException))
    {
        DBGOUT_LASTERROR (_T("Open (%s)\n"), pPath);
        return FALSE;
    }

Download source – 24KB

Date Posted: 07/07/98

CodeGuru Logo

CodeGuru covers topics related to Microsoft-related software development, mobile development, database management, and web application programming. In addition to tutorials and how-tos that teach programmers how to code in Microsoft-related languages and frameworks like C# and .Net, we also publish articles on software development tools, the latest in developer news, and advice for project managers. Cloud services such as Microsoft Azure and database options including SQL Server and MSSQL are also frequently covered.

Property of TechnologyAdvice. © 2026 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.