LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

how to printf() to shell (cmd.exe)

is there any way to direct the output from 'printf()' function to the calling environment - namely cmd.exe ?
purpose: I'm writing CLI programs in cvi which works fine for parsing command line arguments etc... but I would like to have the output from printf() statements go to the command interpreter (cmd.exe) from which the program was called, e.g. for use in batch-files, pipe to other programs etc.
the normal behaviour for printf() is to open a separate window and display output there, which is pretty much useless in my case.


--
Once the game is over, the king and the pawn go back into the same box.
0 Kudos
Message 1 of 4
(8,465 Views)
Are You buildung a console application?

Target Settings... -> Create Console Application
-----------------------
/* Nothing past this point should fail if the code is working as intended */
0 Kudos
Message 2 of 4
(8,455 Views)


@CVI-User wrote:
Are You buildung a console application?

Target Settings... -> Create Console Application





ok,
thanks, I remember having used this option before ... 🙂
what I want, is an application which comes up with the GUI when called without cmd-line arguments,
otherwise behave like described in the OP.
I'll check if this is possible...
--
Once the game is over, the king and the pawn go back into the same box.
0 Kudos
Message 3 of 4
(8,448 Views)
just for the record:
console application is ok for both mentioned purposes.
it just opens a console also when running in GUI mode.
--
Once the game is over, the king and the pawn go back into the same box.
0 Kudos
Message 4 of 4
(8,426 Views)