Skip to content Skip to sidebar Skip to footer

Getting Info (title, Subject, Author, Producer...) From Pdf Using Javascript

Im trying to learn how to use javascript inside pdf files, and how to grab information from the /Info object like author and title. I've found two ways to use js inside a pdf, and

Solution 1:

app.alert(event.target.title);

Solution 2:

This is really a comment, but I use answer for formatting and readability reasons.

http://corkami.googlecode.com/svn-history/r503/wiki/PDFTricks.wiki

If you have

/Info <</Author(Hello) /Title( World) /Producer( !)>>

then you can do

app.alert(info.author + info.title + info.producer);

In your case I would guess you need to get the document you are in first. I doubt you can do what you want since you seem to be embedding an xml file inside the pdf. I would not expect it to work

Post a Comment for "Getting Info (title, Subject, Author, Producer...) From Pdf Using Javascript"