Hi Appium_Master
I have tried your code for scrolling in the android app. below is the code, But still not able to scroll :-
HashMap<String, String> scrollObject = new HashMap<String, String>();
RemoteWebElement element = (RemoteWebElement)((AndroidDriver) driver).findElementByAndroidUIAutomator("new UiSelector().className(\"android.view.View\")");
JavascriptExecutor js = (JavascriptExecutor) driver;
String webElementId = ((RemoteWebElement) element).getId();
System.out.println(webElementId);System.out.println(element);
scrollObject.put("text", "Load more");
scrollObject.put("element", webElementId);
js.executeScript("mobile: scrollTo", scrollObject);
element.click();
But i am getting the below exception
org.openqa.selenium.WebDriverException: An unknown server-side error occurred while processing the command.
at line
js.executeScript("mobile: scrollTo", scrollObject);
Could you please help me in how to do scrolling in android app.
I am using below versions:-
Appium 1.3.4.1
Selenium 2.45
Java-Client 2.2.0
Thanks in Advance!!