<< Click to Display Table of Contents >> VpeSetPaperBin |
[Not supported by the Community Edition]
Sets the paper bin for the current page. Also all newly with PageBreak() added pages will print to this bin.
void VpeSetPaperBin(
VpeHandle hDoc,
int bin
)
VpeHandle hDoc
Document Handle
int bin
can be one of the following values:
Constant Name |
Value |
Comment |
VBIN_UNTOUCHED |
-1 |
default |
VBIN_UPPER |
1 |
|
VBIN_ONLYONE |
1 |
|
VBIN_LOWER |
2 |
|
VBIN_MIDDLE |
3 |
|
VBIN_MANUAL |
4 |
|
VBIN_ENVELOPE |
5 |
|
VBIN_ENVMANUAL |
6 |
|
VBIN_AUTO |
7 |
|
VBIN_TRACTOR |
8 |
|
VBIN_SMALLFMT |
9 |
|
VBIN_LARGEFMT |
10 |
|
VBIN_LARGECAPACITY |
11 |
|
VBIN_CASSETTE |
14 |
|
Not all of the bin options are available on every printer. Check the printer's documentation for more specific descriptions of these options. In addition the PaperBin-ID constants above can not be used reliably. Instead enumerate the available paper bins for the selected printer (please see below for details).
Default:
VBIN_UNTOUCHED
Remarks:
Setting this property on non-Windows platforms has no effect.
This property is independent from DevPaperBin. You should not use DevPaperBin, instead always use this property to specify the paper bin.
The value VBIN_UNTOUCHED is a VPE internal constant. It instructs VPE not to change the bin from the setting the current selected device has.
This property conflicts with the default behavior of VPE, to provide the page dimensions of the currently printed page to the printer driver. Many printer drivers choose automatically the right paper from a different paper input bin. To override the default behavior of VPE and to make the PaperBin property work, you have to specify the flag PRINT_NO_AUTO_PAGE_DIMS for the property PrintOptions.
Do not rely on the bin names of the constants, like VBIN_UPPER, etc. - their names might not match correctly a tray: for example under WinNT for an HP 5P you can select the lower tray with VBIN_LOWER and the upper tray with VBIN_UPPER, but under Win95 for the same printer you can only use VBIN_MANUAL for the upper tray and VBIN_UPPER for the lower tray (yes, it is not a mistake: the LOWER tray is selected with VBIN_UPPER!).
Solution: operate with BIN-ID's (see VpeGetDevPaperBinID) and the corresponding bin names only, see VpeDevEnumPaperBins() and ff.
Changing the bin during the print-job doesn’t work with some (buggy) printer drivers. Changing the bin with such drivers for other pages than the very first page might not work. Our own tests revealed for example that the HP 2200 D driver can only switch once the bin, but thereafter it will not switch the bin again. The HP 5P driver behaves correctly unless multiple copies and collation are selected. If collation is activated, the driver will print all pages except the first multiple times as if non-collation was selected.
Printer drivers are manufactured by vendors independent of IDEAL Software; we make no warranty, implied or otherwise, regarding these product’s performance or reliability.
Example:
VpeSetPaperBin(hDoc, VBIN_UPPER)
Will instruct the printer during printing, to print this page on the upper paper bin (if available).
VpePageBreak(hDoc)
VpeSetPaperBin(hDoc, VBIN_LOWER)
Adds a new page and will instruct the printer during printing, to print this page on the lower paper bin (if available).
VpePageBreak(hDoc)
VpeSetPaperBin(hDoc, VBIN_UPPER)
Adds a third page and will instruct the printer during printing, to print this page on the upper paper bin again (if available).