TestProject Forum

Validating data in an embedded PDF control

In the app I am recording, I have the ability to click a link and display a PDF document within a container in the Chrome browser. I would like to validate strings contained within this document.

In reviewing the PDF Actions add-on, the actions associated with the add-on only seem to work when the PDF file saved locally. Is there any way to use this add-on (or a different one) to read and validate strings within the embedded PDF container instead? If so, can someone provide an example of how I can achieve this?


As you can see page with a preview of PDF doesn’t contain any HTML (elements) selenium uses elements in order to retrieve information from the DOM, if the page doesn’t contain any you cannot interact with it, the other addon utilize the PDF file itself, so downloading is the way to go if you need to verify the PDF file.

Hi Amit,

Along these lines, I have a similar scenario in my project wherein clicking a link in my web application opens a new URL ending with .pdf. Although I can verify the PDF URL from the DOM & the content by using add-on, I was just wondering why testproject recorder cannot interact with the PDF webpage, while my regular selenium WebDriver can. With my Selenium setup, I am able to switch the window and then fetch the PDF URL & validate it on the new PDF web page and then switch back to parent.

Not that I am blocked here, but was just curious why this difference in behavior of the WebDriver.