PRINTERCOUNT function

Purpose

Retrieve the number of available (installed) printers.

Syntax

ncPrinters& = PRINTERCOUNT

See also

LPRINT ATTACH, PRINTER$, XPRINT ATTACH

Example

FUNCTION PBMAIN

  LOCAL ix AS LONG, sPrinters AS STRING

  FOR ix = 1 TO PRINTERCOUNT

    sPrinters = sPrinters & PRINTER$(NAME, ix) & $CRLF

  NEXT

  PRINT sPrinters

END FUNCTION