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 |
---|---|---|
The PDF reference returned from DynaPDF.New. | ||
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:
Format | Size in units (Width x Height) |
DIN A3 | 842.0 x 1191.0 |
DIN A4 | 595.0 x 842.0 |
DIN A5 | 419.0 x 595.0 |
DIN B4 | 709.0 x 1001.0 |
DIN B5 | 499.0 x 709.0 |
DIN B6 | 354.0 x 499.0 |
DIN C3 | 918.0 x 1298.0 |
DIN C4 | 649.0 x 918.0 |
DIN C5 | 459.0 x 649.0 |
DIN C6 | 323.0 x 459.0 |
DIN C65 | 323.0 x 649.0 |
DIN DL | 312.0 x 624.0 |
DIN E4 | 623.0 x 879.0 |
DIN E5 | 439.0 x 624.0 |
DIN E6 | 312.0 x 439.0 |
DIN E65 | 312.0 x 624.0 |
DIN M5 | 439.0 x 632.0 |
DIN M65 | 317.0 x 632.0 |
US Legal | 612.0 x 1008.0 |
US Letter | 612.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
- DynaPDF.AppendPage
- DynaPDF.GetPageLayout
- DynaPDF.GetPageWidth
- DynaPDF.New
- DynaPDF.SetBBox
- DynaPDF.SetDateTimeFormat
- DynaPDF.SetNumberFormat
- DynaPDF.SetPageHeight
- DynaPDF.SetPageMode
- DynaPDF.SetPageWidth
Example Databases
This function checks for a license.
Created 18th August 2014, last changed 18th August 2014