Topics
All
MacOS
(Only)
Windows
(Only)
Linux
(Only, Not)
iOS
(Only, Not)
Components
Crossplatform Mac & Win
Server
Client
Old
Deprecated
Guides
Examples
Videos
New in version:
12.2
12.3
12.4
12.5
13.0
13.1
13.2
13.3
13.4
13.5
Statistic
FMM
Blog
Copies pages from one PDF to append other PDF.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
PDFKit | 3.1 | ✅ Yes | ❌ No | ❌ No | ✅ Yes, on macOS | ✅ Yes |
Parameter | Description | Example |
---|---|---|
PDFRef | The PDF Reference where pages are added. | $ref |
OtherPDFs | Several PDF references. A container value with the PDF content from a media field. Or a text with an URL. Or a PDF reference from PDFKit.Open. |
Returns OK on success or error on failure.
Merge two PDFs:
Set Variable [ $pdf ; Value: MBS("PDFKit.OpenContainer"; MyTable::InputPDF) ]
Set Variable [ $r ; Value: MBS( "PDFKit.AppendPages"; $pdf; MyTable::OtherPDF ) ]
Set Field [ MyTable::OutputPDF ; MBS( "PDFKit.GetPDFDocument"; $PDF) ]
Set Variable [ $r ; Value: MBS( "PDFKit.Release"; $pdf) ]
Loop over PDF documents in records and import them into a new PDF and add empty pages between:
Go to Record/Request/Page [ First ]
Set Variable [ $pdf ; Value: MBS( "PDFKit.NewPDFDocument" ) ]
Loop
Set Variable [ $r ; Value: MBS( "PDFKit.AppendPages"; $pdf; Merge PDFs::InputPDF) ]
Set Variable [ $r ; Value: MBS( "PDFKit.AddEmptyPage"; $pdf; 700; 500) ]
Go to Record/Request/Page [ Next ; Exit after last: On ]
End Loop
Set Field [ Merge PDFs::FinalPDF ; MBS("PDFKit.GetPDFDocument"; $pdf) ]
Set Variable [ $r ; Value: MBS("PDFKit.Release"; $pdf) ]
This function checks for a license.
Created 18th August 2014, last changed 28th September 2021