To create a new file, one clicks on FILE in the upper bar menu, and then on NEW. Opening an old file, and saving files are done via the same menu.
To compile a program, one can either click on PROJECT in the upper bar menu, and then on COMPILE or merely press Alt-F9.
After compilation (without errors), to run a program, one can either click on DEBUG in the upper bar menu, and then on RUN or merely press Ctrl-F9.
NOTE: Most PC-program will use internal file handling statements to open and close input and output files. In cases where one wants to write to the screen, one should include the statement
cin.getch();
or
cin >> i;
(where i is declared as a character variable)
right before the final return 0; statement in the main
program. This will keep the output window open until a key is
depressed. Otherwise, it will open and close immediately (usually
before anyone can read anything on the screen!).
One invokes Borland C++ Builder 4 by clicking on the Programming Languages folder, then clicking on the Borland C++ Builder 4 folder, and then on the Borland C++ Builder 4 Icon.
After Builder 4 is launched, many windows will appear along with a menu bar across the top.
To edit and compile simple programs, reset the environment as follows.
FIRST, click on FILE in the upper bar menu, and then on CLOSE ALL.
THEN, click on FILE again, and then on NEW.
A NEW ITEM window will appear with many options. Click on the CONSOLE WIZARD icon, and another window will appear. In this window, make sure that for "Window Type" Console is checked and for "Execution Type" EXE is checked, then click on FINISH.
A new editing window will appear with a skeleton of code for you to fill in. You may wish to highlight all the code and delete it or merely delete those aspects that you will not need.
To compile a program, one can either click on PROJECT in the upper bar menu, and then on MAKE or merely press Ctrl-F9.
After compilation (without errors), to run a program, one can either click on RUN in the upper bar menu, and then on RUN or merely press F9.
This page is maintained by Dennis C. Smolarski, S.J.
dsmolarski@math.scu.edu
© Copyright 1999 Dennis C. Smolarski, SJ, All rights reserved.
Last changed: 7 October 1999