PSSetPaperBin() / PSSetBin()

Syntax

Function PSSetPaperBin(nBin)
TPageScript:SetPaperBin(nBin)

Returns

The old paper bin.

Description

PSSetPaperBin() lets you select the paper bin (also called paper tray or paper source) when your printer has more than one tray. Standard paper bins numbers are defined in Windows but are rarely supported by the printer driver's manufacturer. Instead, use PSGetPaperBinNumbers() to retrieve the exact bin number associated with a tray. Call this procedure before starting a new document.

Arguments

nBin Bin number to select

Predefined paper bins (based on Windows API constants)

Constant Value Description
DMBIN_UPPER 1 Upper bin
DMBIN_FIRST 1 Same as Upper bin
DMBIN_ONLYONE 1 Same as Upper bin
DMBIN_LOWER 2 Lower bin
DMBIN_MIDDLE 3 Middle bin
DMBIN_MANUAL 4 Manual feed
DMBIN_ENVELOPE 5 Envelope
DMBIN_ENVMANUAL 6 Envelope manual feed
DMBIN_AUTO 7 Auto select (depending on paper size)
DMBIN_TRACTOR 8 Tractor feed
DMBIN_SMALLFMT 9 Small forms
DMBIN_LARGEFMT 10 Large forms
DMBIN_LARGECAPACITY 11 Large capacity bin
DMBIN_CASSETTE 14 Cassette
DMBIN_FORMSOURCE 15 Form source
DMBIN_LAST 15 Same as Form source
DMBIN_USER 256 Device specific bins start here