xcall MIAMEX, MX_WINPTR, status, printer {port, driver, orientation, length, width, formname, duplex, bin, color, resolution}
(Windows/ATE) MX_WINPTR (MIAMEX 120) displays a standard Windows printer selection dialog and returns information about the printer selected. This might be useful for building printer initialization files (see Defining Spoolers) based on the selected printer. Or, you can take it one step farther and just use the full Windows printer name (as returned in the printer parameter) directly when sending files to the printer. For more information, see EZSPLxs and PRINT.LIT.
This function has both a subroutine and a print tab implementation.
Note that this operation can only take place on a GUI-enabled client, either ATE or some form of A-Shell/Windows.
Parameters
All parameters are [out].
Parameter |
Type |
Description |
---|---|---|
status |
Num |
0: User cancelled out of the printer selection dialog |
printer |
the descriptive printer name of the printer selected by the user. This is normally the name which appears under the icon in the printer selection window. |
|
port |
port name. This could be a traditional physical port (like LPT1:), or a logical network port (like NET01: or IP_192.158.200.250). |
|
driver |
name of the driver. In most cases with newer versions of Windows, this will be the universal spooler driver "winspool" (which in turn calls the hardware-specific driver). |
|
orientation |
Num |
1=portrait, 2=landscape |
length |
Num |
paper length in tenths of millimeters |
width |
Num |
paper width in tenths of millimeters |
formname |
name of form (e.g. "Letter", "Legal", etc.) |
|
duplex |
Num |
1=simplex, 2=duplex (vert), 3=duplex (horz) |
bin |
Num |
bin number |
color |
Num |
1=monochrome (B & W), 2=color |
quality |
Num |
If greater than zero, indicates the resolution in DPI. Otherwise: -1 = draft, -2 = low, -3 = medium, -4 = high. |
See Also