Forum Discussion

tsan123's avatar
tsan123
Occasional Contributor
8 years ago

Getting Text from pdf and validate if the form exists

Hello all,

 

Need help to view the downloads and verify if the cover letter and a form are attached to packet.

 

Used the  function below and was able to view the text in additional info. Can anyone let me know what I need to do in order to test if the above mentioned documents are attached in pdf file. I cannot identify the text with object spy in pdf doc.

 

Please suggest Thanks in Advance.

 

Sub Test

Dim strFileName, doc, pdfStripper, str 

strFileName = "C:\Users\Downloads\Test.pdf" 

Set doc = dotNET.org_apache_pdfbox_pdmodel.PDDocument.load(strFileName)

Set pdfStripper = dotNET.org_apache_pdfbox_util.PDFTextStripper.zctor_2

sys.HighlightObject(pdfStripper) 

str = pdfStripper.getText_2(doc)

Call Log.Message("See Additional Info", str)

End Sub

 

 

3 Replies