This function is used to set permanently or for the current session the PrinterName printer with an Orientation orientation for the PrinterNum printer number.
Prints in local mode: if the PrinterName parameter is not specified, the standard printer selection box is displayed (via the function VaToolBxChoosePrinter).
Context
Windows client,
Adelia Cloud client,
Event Adelia client.
Parameters
NUM_BIN_2 |
PrinterNum |
Number of the printer (from 1 to 9). |
BOOL |
Permanent |
Specifies whether or not the new parameters are taken into account for the current session only (*FALSE) or permanently (*TRUE) (the configuration file will be modified). |
ALPHA |
PrinterName |
Name of the printer. To designate the default printer, use the following value: 'DEFAULT PRINTER'. |
NUM_BIN_2 |
Orientation |
1 = Portrait, 2 = Landscape. |
BOOL |
ReturnCode |
Return code for the operation: *TRUE if the operation was successful. *FALSE if the operation failed. |
Example
PrinterNum |
= 1 | |
Permanent |
= *FALSE | *sets the parameters for the session (lifetime of the process) |
PrinterName | = '\\SRVIMPR\MONIMP' | |
Orientation |
= 1 | *Portrait |
ReturnCode |
= *TRUE |
CALL_DLL 'VATOOLBX.DLL' 'VaToolBxSetPrinter' PrinterNum Permanent PrinterName Orientation ReturnCode
List of the VaToolBx functions by topic