I have a SAP Application and there is dialog box as shown below:
the html source code of this respective dialog box is
As we can see that there is only 18 row when I scroll the bar (show with blue arrow in pic 1) html source code shows another 18 rows since only the 18 row can fit in the dialog box. Now I want to scroll the bar into last and select the last row of the box. How can I do this??
I tried using
public void waitForElement()
{
//IJavaScriptExecutor je = (IJavaScriptExecutor)StaticDriver.driver;
//IWebElement element = StaticDriver.driver.FindElement(By.XPath("(//*[@class= 'slick-cell l0 r0 row_62 cid_col_0']//div)//following-sibling::div"));
//je.ExecuteScript("arguments[0].scrollIntoView(true);", element);
var element = StaticDriver.driver.FindElement(By.XPath("(//*[@class= 'slick-cell l0 r0 row_62 cid_col_0']//div)//following-sibling::div"));
Actions actions = new Actions(StaticDriver.driver);
actions.MoveToElement(element);
actions.Perform();
}
// that xpath is the element of last row.
but i got error Element count be found
How Can I Scroll to the last and find the element?
The View and html source code for last element is: