I am using Custom ListView
in Android and everything is working fine fetching data into list. Earlier the click event working fine with it but when I applied custom TextView
and LinerLayout
with a custom background in litst_view_item.xml file its click event not working right now please help me.
How can I remove this error ?
I tried all code samples like :
android:focusable="false"
android:focusableInTouchMode="false"
in every layout item in list_view_item.xml (even in linearlayout)
and
android:descendantFocusability="blocksDescendants"
in listview_activity.xml file
in listview attribute and in its parent LinearLayout.xml
Please if someone know about this problem, please help me
Copyright Notice:Content Author:「Sahitya Kumar Suman」,Reproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/32716028/android-listview-clickevent-not-working