Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old

DynaPDF.SetPageFormat

The function sets a predefined page or paper format.

Component Version macOS Windows Linux Server iOS SDK
DynaPDF 3.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "DynaPDF.SetPageFormat"; PDF; Value )   More

Parameters

Parameter Description Example
PDF The PDF reference returned from DynaPDF.New. $pdf
Value The new value. "DIN A4"

Result

Returns OK on success or error message.

Description

The function sets a predefined page or paper format.
If an open page can be detected the format of the page will be changed, the new format will also be used for newly created pages. If no open page is detected, the default format for new pages will be set only. This function changes the media box of a page (see DynaPDF.SetBBox for further information).
Valid values are: DIN A3, DIN A4, DIN A5, DIN B4, DIN B5, DIN B6, DIN C3, DIN C4, DIN C5, DIN C6, DIN C65, DIN DL, DIN E4, DIN E5, DIN E6, DIN E65, DIN M5, DIN M65, US Legal or US Letter.
See also DynaPDF.GetPageWidth, DynaPDF.GetPageHeight, DynaPDF.SetPageHeight and DynaPDF.SetPageWidth.

Common paper formats and sizes in points:

FormatSize in units (Width x Height)
DIN A3842.0 x 1191.0
DIN A4595.0 x 842.0
DIN A5419.0 x 595.0
DIN B4709.0 x 1001.0
DIN B5499.0 x 709.0
DIN B6354.0 x 499.0
DIN C3918.0 x 1298.0
DIN C4649.0 x 918.0
DIN C5459.0 x 649.0
DIN C6323.0 x 459.0
DIN C65323.0 x 649.0
DIN DL312.0 x 624.0
DIN E4623.0 x 879.0
DIN E5439.0 x 624.0
DIN E6312.0 x 439.0
DIN E65312.0 x 624.0
DIN M5439.0 x 632.0
DIN M65317.0 x 632.0
US Legal612.0 x 1008.0
US Letter612.0 x 792.0

See also SetPageFormat function in DynaPDF manual.

Examples

Set to DIN A3:

MBS( "DynaPDF.SetPageFormat"; $PDF; "A3" )

Set to US letter:

MBS( "DynaPDF.SetPageFormat"; $PDF; "US Letter" )

See also

Example Databases

This function checks for a license.

Created 18th August 2014, last changed 18th August 2014


DynaPDF.SetPageCoords - DynaPDF.SetPageHeight