Skip to content
Guides

Document Information

This example shows how to get document information:

java
CPDFDocument document = new CPDFDocument(context);
document.open(pdfPath);
CPDFInfo info = document.getInfo();
String title = info.getTitle();          // Document title.
String author = info.getAuthor();        // Document author.
String subject = info.getSubject();      // Document subject.
String creator = info.getCreator();      // Application name that created the document
String producer = info.getProducer();    // Application name that generated PDF data
String keywords = info.getKeywords();    // Document keywords.
String creationDate = info.getCreationDate();	// Document creation date
String modificationDate = info.getModificationDate();    // Document last modified date
kotlin
val document = CPDFDocument(context)
document.open(pdfPath)
val info = document.info
val title = info.title        				// Document title.
val author = info.author      				// Document author.
val subject = info.subject     				// Document subject.
val creator = info.creator     				// Application name that created the document
val producer = info.producer    			// Application name that generated PDF data
val keywords = info.keywords    			// Document keywords.
val creationDate = info.creationDate	// Document creation date
val modificationDate = info.modificationDate    // Document last modified date