@Tutor, Thanks for putting up short and to the point videos. I have question regarding capturing screenshot. What should I do in case I have to take the screenshot of whole page as one image. Currently it takes only the portion which is displayed. Our webpage is quite long and we have scroll down to access it.
Hi Anirudh, Thank you very much for your feedback. As of now capturing the screenshot of the entire webpage is not yet implemented. As a work around you could scroll down your webpage to a particular web element and then take the screenshot. The code snippet for the same is: Using openqa.selenium.interactions; Iwebelement element =driver.Findelement(By.id("xyz")); Actions actions = new Actions(driver); actions.MoveToElement(element); actions.Perform(); //Capture screenshot code goes here
Hi, I have a below error: Cannot convert from 'System.Drawing.Imaging.ImageFormat' to 'OpenQA.Selenium.ScreenshotImageFormat' How can I solve this issue?
i am getting unauthorised acess exception to the path given how to solve this.plz reply
@Tutor,
Thanks for putting up short and to the point videos.
I have question regarding capturing screenshot. What should I do in case I have to take the screenshot of whole page as one image. Currently it takes only the portion which is displayed. Our webpage is quite long and we have scroll down to access it.
Hi Anirudh,
Thank you very much for your feedback.
As of now capturing the screenshot of the entire webpage is not yet implemented.
As a work around you could scroll down your webpage to a particular web element and then take the screenshot.
The code snippet for the same is:
Using openqa.selenium.interactions;
Iwebelement element =driver.Findelement(By.id("xyz"));
Actions actions = new Actions(driver);
actions.MoveToElement(element);
actions.Perform();
//Capture screenshot code goes here
Hi,
I have a below error:
Cannot convert from 'System.Drawing.Imaging.ImageFormat' to 'OpenQA.Selenium.ScreenshotImageFormat'
How can I solve this issue?
You need to change "ImageFormat" by "ScreenshotImageFormat".