Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Vertical Scroll down and scroll up in Selenium WebDriver with java

Can anybody please help me out to automate scroll down functionality with WebDriver using Java?

In my case, For yahoo mail "Sign In" is getting displayed (visible) once I scroll down the mouse vertically.

like image 931
Muna Avatar asked Jul 19 '12 05:07

Muna


1 Answers

Scrolling to an Element of a page:

((JavascriptExecutor)driver).executeScript("arguments[0].scrollIntoView();"
                                                              ,webElement);
like image 140
Aerien Avatar answered Sep 30 '22 20:09

Aerien