Get the number of available printers.
getNumPrinters([out, retval] int *numPrinters)
This function returns the number of available printers.

Note: getNumPrinters and getPrinterName are just simple wrappers around Windows functions. There is no requirement to use these functions if you already know the printer name that you want to use.

nPrinters = viewer.getNumPrinters() For i = 0 To nPrinters - 1 printerName = viewer.getPrinterName(i) print("printer " & i & ": " & printerName) Next i