Android list item has no click effect here is what to do

 Add the following code to your list item


android:background="?android:attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"


See the screenshot









If you want to remove border in listview , add the code in listview xml

android:divider="@null"
android:dividerHeight="0dp"
OR
android:divider="@android:color/transparent"

OR


<ListView android:id="@+id/my_list_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:divider="@null"
    />










Comments