Output to be redirected from console to file..

I

iceColdFire

HI,

I have an MFC application...I have used Memory Leak functions, as

CMemoryState a,b;

Now, a.DumpStatistics() send all its output to the console.... I need
to get this output into a file...

kindly suggest...

I have alreay tried freopen(..) and ofstream type...but nothing seems
to work...

thanks
a.a.cpp
 
H

Howard

iceColdFire said:
HI,

I have an MFC application...I have used Memory Leak functions, as

CMemoryState a,b;

Now, a.DumpStatistics() send all its output to the console.... I need
to get this output into a file...

kindly suggest...

I have alreay tried freopen(..) and ofstream type...but nothing seems
to work...

Well, MFC stuff should be directed to an mfc newsgroup, since it's their
software. But assuming they're just using cout, it may be possible to use
something like cout.rdbuf() to redirect it elsewhere. (I just saw that in
another post, and don't know the details of it, so you need to look it up or
Google for it to get better info.)

-Howard
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top