XPRINT SET PAPER statement  

Purpose

Set a new paper size/type.

Syntax

XPRINT SET PAPER papertype&

Remarks

XPRINT SET PAPER changes the paper style for the host printer to that designated by papertype&.  The paper style is identified by an integer value given in the expression papertype&.  The following equates are predefined in the compiler, and represent the most common paper styles:

%DMPAPER_LETTER    =  1      Letter    8.5   x 11    inches
%DMPAPER_TABLOID   =  3      Tabloid   11    x 17    inches
%DMPAPER_LEDGER    =  4      Ledger    17    x 11    inches
%DMPAPER_LEGAL     =  5      Legal     8.5   x 14    inches
%DMPAPER_STATEMENT =  6      Statement 5.5   x 8.5   inches
%DMPAPER_EXECUTIVE =  7      Executive 7.25  x 10.5  inches
%DMPAPER_A3        =  8      A3        297   x 420   mm
%DMPAPER_A4        =  9      A4        210   x 297   mm
%DMPAPER_A5        = 11      A5        148   x 210   mm
%DMPAPER_B4        = 12      B4        250   x 354   mm
%DMPAPER_B5        = 13      B5        182   x 257   mm
%DMPAPER_FOLIO     = 14      Folio     8.5   x 13    inches
%DMPAPER_QUARTO    = 15      Quarto    215   x 275   mm
%DMPAPER_10X14     = 16      10x14     10    x 14    inches
%DMPAPER_11X17     = 17      11x17     11    x 17    inches
%DMPAPER_NOTE      = 18      Note      8.5   x 11    inches
%DMPAPER_ENV_9     = 19      9 Envlp   3.875 x 8.875 inches
%DMPAPER_ENV_10    = 20      10 Envlp  4.125 x 9.5   inches

Other paper style codes may be defined by Windows or printer suppliers. You can use XPRINT GET PAPERS to obtain a list of all the paper styles supported by the attached host printer.

If the printer does not support the paper style specified, error 5 is generated.  If executed without a host printer attached, error 57 is generated.

See also

XPRINT ATTACH, XPRINT GET PAPER, XPRINT GET PAPERS