I am aware that we can use the below to scroll down on the webpage.
(JavascriptExecutor) driver.executeScript("window.scrollBy(0,1000)");
But I have a particular section in the webpage, which has a scroll bar. I need to go to the last element in that section. Problem is the last element's locator will not be found until and unless I scroll down completely. How do we handle it?