TPDFlibAttachment
Data Types
Description
TPDFlibAttachment is a unified record structure that describes an embedded file attachment, whether it originates from a document-level name tree or a page-level file attachment annotation.
Syntax
Delphi
type TPDFlibAttachment = record
Source: TPDFlibAttachmentSource;
Index: Integer;
Page: Integer;
FileName: WideString;
MIMEType: WideString;
Description: WideString;
Size: Int64;
end;Fields
| Source | The attachment origin specified by TPDFlibAttachmentSource. |
|---|---|
| Index | The 1-based index within its own source collection (e.g. within the embedded file list or the page annotation list). |
| Page | The 1-based page number where the attachment resides if Source is asAnnotAttachment; otherwise 0 if it is document-wide (asEmbeddedFile). |
| FileName | The name or Unicode path specifier of the attached file. |
| MIMEType | The MIME content subtype of the embedded stream (e.g., image/jpeg or application/xml). |
| Description | A descriptive text comment for the attachment. |
| Size | The uncompressed stream file size in bytes; returns 0 if size metadata is absent. |
See also
TPDFlibAttachmentSource, EnumAttachments, SaveAllAttachments