I am creating lists in my android app and would like to capture the text of the list item that is clicked but I want to do it in a seperate function so I only have to write the code once. And I want to be able to compare the string to another sting.
What is the best way to do this?
You need OnItemClickListener() set to your list and overwrite
then get you text either from item itself or from the view.