How to take screen shot from top to bottom of a web page?

Hi in a web page i need to take screen shots for 2 sections in a webpage which is at top and another at bottom. Tried with mouse scroll activity but not getting full picture. So trying with entire page. Can anyone please help?

Hello @vnsatyasunil

Open the web page in a browser
Open Browser activity (URL: “https://example.com”)

Capture screenshot of the top section
Take Screenshot activity (Save to file: “top_section.png”)
Click activity (Navigate to the top section, if needed)

Execute JavaScript to scroll to the bottom
Execute JavaScript activity (JavaScript code: “window.scrollTo(0, document.body.scrollHeight);”)

Capture screenshot of the bottom section
Take Screenshot activity (Save to file: “bottom_section.png”)

Thanks & Cheers!!!

Hi @vnsatyasunil ,
When you open website,
that is top of page, that’s right
before take screen short, you can check elements exist

go to end of page by send hot key ctrl+end
or mouse scroll
check elements exist before take screen short,
hope it help,

Some options if you want a full page screenshot:
a) install a browser extension that allows full page screenshots, and have robot use it (look for extensions in Chrome/Edge web stores)
b) developer tools (Take Whole page Screenshot in chrome without extension - #7 by lukasziebold)
c) print the page as pdf and convert the pdf to an image (Take Screenshot of a Long Page - #4 by harshit_singh).

1 Like

We have to scroll to particular element and take screenshot. Used mouse scroll activity but some times due to element changes it is failing. So trying to take entire page screenshot.?
Is that possible?