If you want to use the default printer and font, simply assign your print file to -P SPOOLER. For example, to assign PRINTER to the spooler, enter the following line in your COBOL configuration file (CBLCONFI):


By default, the runtime system assigns the PRINTER device to the spooler. You may change this in the configuration file by assigning PRINTER to some other name.

When the runtime opens a file assigned to -P SPOOLER, it automatically initiates a job with the Windows spooler and constructs print pages in accordance with your program. The runtime uses the default printer and font. If the user looks for the job in the spooler, it is named with the current title of the ACUCOBOL-GT window.

Note: The Windows spooler operates by drawing your report on each page. It constructs its own control codes to handle formatting. If you assign your print file to -P SPOOLER and your file contains device-dependent control sequences (such as those used to shift to a condensed font, or to print a form and then fill it in), the codes will be passed to the spooler as data and thus will not be interpreted correctly. If you have reports that depend on embedded control codes, print those directly to the device, or assign the print file to -P SPOOLER-DIRECT, as described in Direct Control.