I have windows application in C++.
At the end which prints
printf_s("Application normally closed with return code: %d", ExitCode);
When run this application on command promp by calling executable,
application prints the message succssfully on command prompt.
But if tried calling exeutable on Powershell.
The application executes perfectly but at the end does not print message on console.
Is there any seting do I need to do in powershell for executing application?
or is there any setting I need to do in my application to run it in powershell?
If you have a native commandlin application an commanline window should open and display al contents there.
From what I know you must use managed code to use the enhanced possibilities of the power shell.
I have been watching this issue for a while now. I suggest you try ouputing the contents to other places, such as a text document or a console window, instead of the powershell window.
Helen Zhao [MSFT]
MSDN Community Support | Feedback to us
The same C++ application showing output on my friends powershell window but not showing on my powershell screen.
Is there any setting that I need to do in powershell to view output?
Does it use "plain vanilla" stdio or something else like WriteConsole?