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:
9.5
10.0
10.1
10.2
10.3
10.4
10.5
11.0
11.1
11.2
Statistic
FMM
Blog
Attaches a file to the document.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
DynaPDF | 6.0 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
Parameter | Description | Example | Flags |
---|---|---|---|
The PDF reference returned from DynaPDF.New. | |||
Text | The text content for the file. | $xml | |
TextEncoding | The text encoding for the text. Possible encoding names: ANSI, ISO-8859-1, Latin1, Mac, Native, UTF-8, DOS, Hex, Base64 or Windows. More listed in the FAQ. |
"UTF-8" | |
FileName | The file name to display in PDF viewer. | "ZUGFeRD-invoice.xml" | |
Description | The description for the file. | "invoice.xml" | Optional |
Compress | Pass 1 to compress or 0 to not compress. You should pass 1 for text data like XML or JSON. |
0 | Optional |
Returns OK or error.
Add ZUGFeRD invoice xml file:
Set Variable [$FileHandle; Value:MBS("DynaPDF.AttachFileText"; $pdf; ZUGFeRD Invoice::Invoice XML; "UTF-8"; "ZUGFeRD-invoice.xml"; "Invoice as XML")]
Set Variable [$r; Value:MBS("DynaPDF.AssociateEmbFile"; $pdf; "Catalog"; -1; "Alternative"; $FileHandle)]
Created 16th December 2015, last changed 12nd February 2021
DynaPDF.AttachFileContainer - DynaPDF.BeginContinueText
Feedback: Report problem or ask question.