Hi,
I am trying to save the contents of the command input-output window into a text file, could anyone show me how please?
Thanks
3 Answers
0
You can direct output that is sent to the program input/output window with the output function like this:
//Redirect all printed output to a file 'myoutput.txt'
//'reset' means overwrite the file if it already exists
output file = myoutput.txt reset;
//print some output
print "This output will also be printed to my 'myoutput.txt'";
//Stop sending output to 'myoutput.txt'
output off;
You can also select some text with your mouse and copy it to the clipboard with CTRL+C and then paste it with CTRL+V. To copy the entire contents of the window, click in the window and then CTRL+A to select all, then CTRL+C to copy and CTRL+V to paste.
0
Hi, thanks for the reply. I will try the first method in my next run of the program. I am currently running a large program, and I tried the second method but copying it does not go all the way to the top. Is it possible to retrieve the existing output after the program finishes running?
0
CTRL+A will select all of the output that is currently in the program input/output window.
By default the program input/output window only keeps the last 20,000 lines. You can increase the number of lines that are kept by going to Tools->Preferences->Command and changing the number in 'Output Buffer Size (lines)'.
Your Answer
3 Answers
You can direct output that is sent to the program input/output window with the output function like this:
//Redirect all printed output to a file 'myoutput.txt'
//'reset' means overwrite the file if it already exists
output file = myoutput.txt reset;
//print some output
print "This output will also be printed to my 'myoutput.txt'";
//Stop sending output to 'myoutput.txt'
output off;
You can also select some text with your mouse and copy it to the clipboard with CTRL+C and then paste it with CTRL+V. To copy the entire contents of the window, click in the window and then CTRL+A to select all, then CTRL+C to copy and CTRL+V to paste.
Hi, thanks for the reply. I will try the first method in my next run of the program. I am currently running a large program, and I tried the second method but copying it does not go all the way to the top. Is it possible to retrieve the existing output after the program finishes running?
CTRL+A will select all of the output that is currently in the program input/output window.
By default the program input/output window only keeps the last 20,000 lines. You can increase the number of lines that are kept by going to Tools->Preferences->Command and changing the number in 'Output Buffer Size (lines)'.