This is the code I use to redirect stderr to the file
if (_wfreopen(L"stderr.txt",L"a+",stderr) == NULL)
{
fputs("Failed to reopen stderr", stderr);
}
and after this statement I use some api ABCD(...) which writes some
messages to stderr
in this case it does not write any message to the file.
If I uncomment above redirection then calling the api does write the
messages to the console screen(which by default is stderrr).
Please let me know hwo can I redirect these messages to the file!!!
Thanks,
Navanath
ndessai wrote:
Hi All,
I had a project which used to redirect stderr to a file in VC 6.
(working fine)
When I ported it to VC 7 it does not put messages in the file.
Any ideas???
Thanks,
Navanath