Redirecting program output to file 
Author Message
 Redirecting program output to file

Hi,

You know all these programs that show a message when quiting, and you
could also run them like Myprogram > testfile, which will cause the
screen output to go to a file named testfile instead than to the
screen.

How is that done?

TIA_JACK



Mon, 25 Apr 2005 04:20:12 GMT  
 Redirecting program output to file
Jack,

Quote:
>You know all these programs that show a message when quiting, and you
>could also run them like Myprogram > testfile, which will cause the
>screen output to go to a file named testfile instead than to the
>screen.

>How is that done?

#define STDOUT 1
#define CRLF chr(13)+chr(10)
fwrite(STDOUT,"This message is sent to STDOUT"+CRLF)

Then run the application with and without redirection to see where the
output goes.

Klas

-------
klas dot engwall at engwall dot com




Mon, 25 Apr 2005 07:50:31 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. redirecting program output to the stack

2. Redirecting DOS program output to text window

3. Redirecting Output to files

4. Redirecting to TWO output files

5. how to redirect lpt1 to file-output

6. redirect g77 output into a file under windows xp

7. redirect output of functions to a string or file

8. Redirect file output into variables

9. redirect g77 under DOS 6.22- need output file

10. expect: redirect output into file called `uname -n'.txt

11. redirect exec output to a file

12. Redirecting output to a scratch file

 

 
Powered by phpBB® Forum Software