Requirement to automate pdf which is getting opened in new tab

Hi Team,

I have a requirement to automate pdf which is being opened in new tab.

Steps:

  1. On Clicking “Print” button from the Application under test.
  2. PDF is getting opened in new tab of the same browser.

Requrirement is to automate this pdf which is getting opened in the new tab of the same browser.
Screenshots attached.

Please let me know the appropriate solution.

Hi,
Try use a Switch To Windows Index step on index = 1

@HeleneB
Thanks for the solution. I will try that.
How can I verify the content of the pdf which is being opened in the browser?

You can use verify text present by default.
You also can try the plugin https://store.katalon.com/product/61/PDF-Keywords or you have to create your own Keywords for others functions

@HeleneB
Is there any way to download the file on clicking download button, as shown in screenshot.

Please note that file to be downloaded is getting opened in chrome browser tab.

You can create an object for the button, and use a click step on it.
But after that, you’ll have to use a Java.Robot to interact with the windows pop-up, or a step like WebUI.sendKeys(null, Keys.chord(Keys.ENTER))