Microsoft Visual C++:
Under the DOS/Win NT environment, you should run your program using the IDE rather than as a stand-alone executable. To do this, select the "Build" Option from the MSVC menu items and click on "Execute p0.exe" (or the proper name of the executable ).
The first time, the program runs it brings up a window containing only the last 24 lines of your code output. In order to get all the output, click on the top left hand side corner of the DOS window. (where it shows an MS-DOS icon). From the menu options available, click on Properties. This brings up a window as shown in the following figure.
In the "Layout" page in the Window, you need to make a change to the Height of the "Screen Buffer Size" section of the window. Change the "Height" field of that Window to 250 (from 25). This should be sufficient to even accommodate the output of a reasonably large size project in the course. Once this is done, click on the OK button. It then brings up a little Dialog Box as follows:
Choose the second option ie "Save properties for future windows with same title" and click OK again.
From now on your program output window for your code will be capable of having 250 lines. There will be a scroll bar that will start appearing once the number of lines exceeds 25.
Now, run your program again and get the output on the window (with scroll bar). You can use the traditional CUT-PASTE technique to get the output in a file as follows.
After the program is run, click on the MS-DOS menu item again, Click on "Edit" option first and then the menu item "Mark". Use your mouse to mark the area you want to appear in the output file. Once you are done marking, click once again on the MS-DOS menu item again, Click on "Edit" option first and then the menu item "Copy". At this point the output has been copied onto a temporary space.
Now go back to your Visual C++ IDE and open a new file, by clicking on the leftmost toolbar icon. (By default only a text file is created). Then, from the MSVC menu item Edit, click on Paste. Now, the output should appear in the new file window, you just created.
Use File+Print option to print the output from within the MSVC++ IDE.