Microsoft KB Archive/119883

{| = How to Print from FoxPro for UNIX =
 * width="100%"|

ID: Q119883

The information in this article applies to:


 * Microsoft FoxPro for UNIX, version 2.6

SUMMARY
FoxPro for UNIX allows both the SCO FoxBASE+ style of printing and the standard FoxPro style of printing.

MORE INFORMATION
SCO FoxBASE+ for UNIX allows you to print with these methods:

Print to Printer
SET PRINT TO "lp -s -dlaser" SET PRINT ON  DISPLAY STATUS TO PRINTER SET PRINTER OFF

Print to File
SET PRINTER TO 'cat > test' * To append to an existing file, the FoxBASE+ command * would read: SET PRINTER TO 'cat >> test' SET PRINTER ON  LIST STATUS TO PRINTER SET PRINTER OFF MODIFY FILE test Note also that the config.fx file for FoxBASE+ can contain the line SPOOLER=cat > /dev/lp0 which directs output to the printer device known as lp0 (the default line printer device number). For local printing, the SCO FoxBASE+ manuals state that the lprint command can be used. For example:

! lprint

FoxPro for UNIX allows you to print with the FoxBASE+ methods as well as the following methods:

Print to Printer
SET DEVICE TO PRINTER SET PRINTER TO "lp -s -dlaser" SET PRINT ON  DISPLAY STATUS TO PRINTER SET PRINTER TO  SET DEVICE TO SCREEN

Print to File
SET DEVICE TO PRINTER SET EXCLUSIVE OFF SET PRINTER TO FILE junk.txt SET PRINTER ON  LIST STATUS TO PRINTER NOCONSOLE SET PRINTER TO           && flush the print buffer SET DEVICE TO SCREEN Note also that "lp -dlaser -s" is a valid method of directing output to the printer called "laser". (The -s switch suppresses the display of the print job identification number.) You can also include _PRN="lp -s -dlaser" in the config.fpu file for FoxPro for UNIX.