CurrentPrinter - PYTHON 不支持

Returns or changes the current Windows printer.

语法

Rhino.CurrentPrinter ([strPrinter])

参数

strPrinter

可选参数。字符串。The name of a Windows printer as returned by this method or by the PrinterNames method.

返回值

String

If strPrinter is not specified, the name of the current Windows printer if successful.

String

If strPrinter is specified, the name of the previously current Windows printer if successful.

Null

如果执行不成功或出错,返回空值。

示例

Dim arrPrinters, strPrinter

arrPrinters = Rhino.PrinterNames

If IsArray(arrPrinters) Then

strPrinter = Rhino.CurrentPrinter

strPrinter = Rhino.ListBox(arrPrinters, "Current:" & strPrinter, "Set Current Printer")

If Not IsNull(strPrinter) Then

Rhino.CurrentPrinter strPrinter

End If

End If

同见

PrinterNames

SpoolToPrinter