Click here to Skip to main content
Licence 
First Posted 17 Dec 2005
Views 14,231
Bookmarked 12 times

use DT,DW and DE in VC++ to output debug info.

By | 17 Dec 2005 | Article
use simple macro to output debug string in debug or release version without VC IDE.

DT_demo.rar

 

Sample screenshot

Introduction

I created three macro to output string in debug or release mode:

DT,DW and DE.

DT is used for output general string.

DW is used for warnning string.

and DE for error.

They are displayed with different colors.

usage is the same as TRACE.

First of all,add #include "dt.h" to stdafx.h

dt.h is include in sourcecode.

demo:

DT("general info,int=%d,errString=%s",1234,"stringDemo");

DW("warnning:%s","StarCraft is my favorite game");

DW("err,something unhappy occurs");

File info and line is add automatically.

Use DT.exe to receive message.

you can find DT.exe in sourcecode directory.

You can write your own DT receiver app,but if somebody want the sourcecode of DT.exe,I will attach it to here.

That's all.

Game over.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

xwp

Software Developer
www.MayGion.com
China China

Member



Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
You must Sign In to use this message board. (secure sign-in)
 
Search this forum  
 FAQ
    Noise  Layout  Per page   
  Refresh
GeneralSuggestions for Improvement PinmemberMike_V6:12 18 Dec '05  
GeneralRe: Suggestions for Improvement PinmemberTankko8:31 18 Dec '05  
AnswerRe: Suggestions for Improvement PinmemberDerMeister22:19 18 Dec '05  

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Mobile
Web01 | 2.5.120517.1 | Last Updated 17 Dec 2005
Article Copyright 2005 by xwp
Everything else Copyright © CodeProject, 1999-2012
Terms of Use
Layout: fixed | fluid