Zusammenfassung
Returns a list of available printer names.
Auswertung
ListPrinterNames is an easy way to identify the names of the printers currently available to the local computer. These string values can then be used as input parameters with the PrintMap() function or the printPages method on the DataDrivenPages object.
Syntax
ListPrinterNames ()
Rückgabewert
Datentyp | Erklärung |
String | Returns a list containing the printer names available to the script. |
Codebeispiel
ListPrinterNames example
Returns a list of printer names available to session.
import arcpy
# Print available printers
printers = arcpy.ListPrinterNames()
for printer in printers:
print(printer)