How to get Scrollbar position of previous Activity using APPIUM or UIAutomator

Hi

We are trying to automate the android app using Appium.

The FirstActivity has 20 items displayed in GridView format.
Selected 10th item, the scrollbarview position is at middle of FirstActivity and navigated to SecondActivity.
The SecondActivity is also having number of list items and navigated through each list item.

We implemented back button functionality using APPIUM in SecondActivity to come back FirstActivity.
When we come back to FirstActivity, sometimes the Scrollbar position going at the top of FirstActivity.
But last position of Scrollbar is middle in FirstActivity.

So, How to get the last/previous position of the scrollbar view in FirstActivity.

Thanks,
Srikanth Turpu

Hmm. Not sure you can. You could have your test script save the name of the element at the top of the current view, then scroll back to that element when you return.