programs have three types of streams. Streams are input and output you give or get from the computer. Standard input(keyboard) standard output( stuff is show on the monitor) and standard error(also monitor). When you do this
program > file.txt
what you are saying is "direct the output that would be come to the screen(stdout) to a file instead"
You can't use the > to redirect standard error to a file, which is probably what you're getting. Instead to this
program 2> file.txt
make sure there are no spaces between the 2 and the >
this means "directe the standard error(stderr) to a file instead of to the screen(which is the default)". If you just use
program > file.txt
then you would be directing the standard output to the file, which it's not what you want in this case
Last edited by kubicon; 09-16-2003 at 09:58 AM.
|