PDF Library for Android

PDF Library for Android

Delphi and C++ Builder library for creating, processing and rendering PDF documents.
  • uses PdfBox-Android library
  • available for Delphi/C++ Builder 10 - 10.4
  • royalty free distribution in applications

Download and order


Why "java.io.FileNotFoundException: open failed: EACCESS (Permission denied)" exception is raised when opening existing PDF file?
You have to request permissions to external storage before using the PDF file:
uses System.Permissions, Androidapi.JNI.Os, ...
    procedure(const APermissions: TArray; const AGrantResults: TArray)
    var PermissionGranted: Boolean;
      PermissionGranted := (Length(AGrantResults) = 1) and (AGrantResults[0] = TPermissionStatus.Granted);
How can I specify page size when creating new page?
Page := Document.AddPage(TPdfPageSize.A4);
How can I change page size?
Page.MediaBox := TPdfPageSize.A4;
How can I retrieve text from PDF document?
  Stripper: JPDFTextStripper;
  Text: string;

Stripper := TJPDFTextStripper.JavaClass.init;
Text := JStringToString(Stripper.getText(Document.Document)); 

Related links