Skip to content Skip to sidebar Skip to footer

Android: Get Row Position From List View

I have ListView. Every row has TextView with some text. And also by default every row has it's position (int value). Can I get row position by text which is in Text View ?

Solution 1:

If you register to receive click events, then the position will come with the event. If you need to find the position outside the scope of click events, then store the position with the view via setTag().


Post a Comment for "Android: Get Row Position From List View"