| xHarbour Reference Documentation > Function Reference |
![]() |
![]() |
![]() |
Checks if a particular printer is installed.
PrinterExists( <cPrinterName> ) --> lInstalled
The function returns .T. (true) if the specified printer is installed, otherwise .F. (false) is returned.
This function checks whether a particular printer is installed or not. The printer name is case sensitive and must be spelled in the exact same way as listed in the control panel.
| See also: | GetPrinters(), GetDefaultPrinter(), IsPrinter(), PrinterPortToName() |
| Category: | Printer functions , xHarbour extensions |
| Source: | rtl\tprinter.c |
| LIB: | xhb.lib |
| DLL: | xhbdll.dll |
// The example outlines case sensitivity of printer names.
PROCEDURE Main()
? PrinterExists( "HP LaserJet 1200 Series PCL" ) // result: .T.
? PrinterExists( "HP LASERJET 1200 SERIES PCL" ) // result: .F.
RETURN
http://www.xHarbour.com