Web SDKv1.0.0

PDFDocument.metadata

Title, author, subject, creator, keywords, producer, creationDate, modifiedDate. modifiedDate is the file's modification date, which a save sets — the saved copy's; the open document's stays what the file said.

Without the extract feature the six strings are ''.

getterPropertiessince 1.0.0

Signature

get metadata(): DocumentMetadata

Returns

DocumentMetadata title, author, subject, keywords (as the file lists them, one string), creator (the application that produced the document), producer (the application that wrote the file), creationDate and modifiedDate (Date | null, null when the file does not say).

Throws

  • DOCUMENT_CLOSED — read on a closed document.

Example

TypeScript
document.title = doc.metadata.title || file.name;

More in PDFDocument