THotPDF.AddDocumentAttachment

THotPDF

 

Top  Previous  Next

Adds any file to the PDF document as a document-level attachment. The EmbeddedFiles name tree keeps its keys in sorted order; when a file bearing the same name is already attached, the new entry is stored under a numbered key such as report (2).txt, so both attachments stay visible, whilst the file name shown to the user stays the original one

 

Delphi syntax:

procedure AddDocumentAttachment ( FileName: TFileName; Description: AnsiString );

 

C++ syntax:

void __fastcall AddDocumentAttachment ( AnsiString FileName, AnsiString Description );

 

Description

Call AddDocumentAttachment procedure to add any file specified FileName  and  Description A file attachment contains a reference to a file, which is embedded in the PDF file.  For example, a table of data might use a file attachment to link to a spreadsheet file based on that data; activating the annotation extracts the embedded file and gives the user an opportunity to view it or store it in the file system