These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Read PDF file contents

tmpalaniselvam
Registered: Aug 1 2008
Posts: 8
Answered

Hi,

I am a tester and I want to automate verifying PDF contents. My application is a web-based and it has few reports and SVG charts. I can export the report and chart as a PDF file. Now I need to verify whether all the report and chart contents are exported to PDF file or not.

I am looking for a VBS/VBA/JS scripting for this verification? I searched this forum and I didnot get the expected one.

I have gone through -> http://www.acrobatusers.com/forums/aucbb/viewtopic.php?id=3121

Advanced Thanks & Regards,
Palani.
http://tips-testing.blogspot.com
Quote: Don`t hesitate to initiate!

My Product Information:
Reader 8.1, Windows
thomp
Expert
Registered: Feb 15 2006
Posts: 4411
Since your app is web based I imagine you are looking for a web based solution? If this is true then Acrobat JavaScript, or anything Acrobat based won't do you any good. You'll need a 3rd party solution that's independant of Acrobat. For example, take a look at iText (http://www.lowagie.com/iText/) . There are also plenty of other tools out there for analyzing and modifying PDFs, just do a google search.

However, I think you might find that the verification is much more difficult than you are imagining. The conversion to PDF changes for SVG and text into PDF graphics and text and organizes them in a very different way than the originals. As an alternative you should take a look at Adobe's Mars technology (http://labs.adobe.com/technologies/mars/). This might make things much easier for you.

Thom Parker
The source for PDF Scripting Info
[url=http://www.pdfScripting.com]pdfscripting.com[/url]

The Acrobat JavaScript Reference, Use it Early and Often
[url=http://www.adobe.com/devnet/acrobat/]http://www.adobe.com/devnet/acrobat/[/url]

Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script

tmpalaniselvam
Registered: Aug 1 2008
Posts: 8
Hi Thom,
Thanks for your reply.

My application is web-based and it will generate PDFs. End users used to download or save the PDF. Now I want to read the contents from the PDF file. iText is not the right choice. I am going through mars.

I am trying to read the PDF file through following VBS statements.
Set AcroApp = CreateObject("AcroExch.App")
Set AcroAVDoc = CreateObject("AcroExch.AVDoc")

Anybody has the VBS to read entire PDF content..?

Advanced Thanks & Regards,
Palani.
http://tips-testing.blogspot.com
Quote: Don`t hesitate to initiate!