TPDFlibAttachmentPanel

Viewer

Description

TPDFlibAttachmentPanel (unit Lib\PDFlibViewer.pas) is a companion panel for TPDFlibViewer that lists the embedded file attachments of the attached document's /EmbeddedFiles name tree, one row per attachment with its name

Syntax

Delphi

TPDFlibAttachmentPanel = Class(TPDFlibViewerPanel)
  Public
    Function SaveAttachmentToFile(Index: Integer;
      Const DestFileName: WideString): Boolean;
  End;

Key members

SaveAttachmentToFileWrites the embedded file behind the 0-based row to DestFileName; False when the index is out of range, no viewer or no document is attached, or the extraction fails

Remarks

The panel rebuilds its rows automatically when a document opens in the attached viewer; the row payload carries the embedded file index used by SaveAttachmentToFile

See also

TPDFlibViewerPanel, TPDFlibViewer, GetEmbeddedFileContentToFile, AddEmbeddedFile