How to do custom ListView with colorful items' backgrounds?

前端 未结 3 509
没有蜡笔的小新
没有蜡笔的小新 2021-01-05 06:15

I have created an ArrayList> collection to hold my data for ListView. I\'m using SimpleAdapter.

3条回答
  •  生来不讨喜
    2021-01-05 06:46

    To accomplish this, you need to create a custom array adapter and then change the background color if the conditions are right.

    Check out this post for an example: Custom ArrayAdapter setBackground in getView

提交回复
热议问题