PrintGetPrinter PowerScript function
Description
Gets the current
printer name.
Syntax
|
1 |
<span>PrintGetPrinter</span> ( ) |
Return Values
String. Returns current printer information
in a tab-delimited format: printername ~t drivername ~t
port.
Usage
The current printer is the default printer unless you change
it with the PrintSetPrinter method. A PowerBuilder
application calling the PrintGetPrinter method
does not get an externally reset default after the application initializes.
Examples
This example places the current printer name, driver,
and port in separate SingleLineEdit textboxes:
|
1 |
String ls_fullstring=<span>PrintGetPrinter()</span><br>String ls_name, ls_driver, ls_port, ls_temp<br>Long ll_placell_place=pos (ls_fullstring, "~t")<br>ls_name=left(ls_fullstring, ll_place -1)<br>ls_temp=mid(ls_fullstring, ll_place +1)<br>ll_place=pos (ls_temp, "~t")<br>ls_driver=left(ls_temp, ll_place -1)<br>ls_port=mid(ls_temp, ll_place +1)sle_1.text=ls_name<br>sle_2.text=ls_driver<br>sle_3.text=ls_port |
See Also
Document get from Powerbuilder help
Thank you for watching.
Subscribe
Login
0 Comments
Oldest