Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Customizing the listview to start from middle

I would like to develop something as shown in the image:

number

And when I click on the number it should display a list view as shown in the second image.

list

Now how can I get the ListView from somewhere in the middle. Actual contents of list start from 58 to say 98. It may not be 72 always.

like image 554
Rohit Walavalkar Avatar asked Jan 29 '26 01:01

Rohit Walavalkar


1 Answers

Use setSelection(position) to jump to index/position where that particular number/item is present ... you will have to create a formula to calculate the index/position http://developer.android.com/reference/android/widget/ListView.html#setSelection(int)

like image 139
baboo Avatar answered Jan 31 '26 15:01

baboo



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!