Where will _CrtDbgReportW be released on Windows Mobile?
I am using the ASSERTE macro to check for preconditions. According to its definition, it uses ASSERT_BASE, which in turn calls _CrtDbgReportW to print the message. Where does the _CrtDbgReportW output go?
I would assume that if the application is launched from the debugger it will go to the debugger window. Where will the messages be sent if they are not under the debugger?
a source to share
The output for _ CrtDbgReportW depends on how you set it up. By default, it sends it to the OutputDebugString API .
Debuggers catch the output of OutputDebugString and usually display it in the debugger window, as you suggest.
There are also applications that capture output, such as DebugView , which you can use for PC applications.
Update: I missed a bit of Windows Mobile. I can still tell that it is being output to OutputDebugString, but I am not aware of any third party application that works. The only way I know to capture the OutputDebugString output under Windows Mobile is to use the DebugActiveProcess / WaitForDebugEvent Debug Functions to catch OUTPUT_DEBUG_STRING_EVENT events and write them somewhere.
a source to share