Question

I have two ListViews in my Activity. I want to use Robotium to select a row in the second list View. When I use solo.clickonText(), it searches for the item on the first listview. How do I select a row in the second listview ?

Was it helpful?

Solution

If you want to click on a particular line of your 2nd list view :

solo.clickInList(int line, 1);

If you want to click on a text in the 2nd list view :

while(!solo.searchText(text_to_click))
{
solo.scrollDownList(1);
}
solo.clickOnText(text_to_click);
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top