开发者

how to set background image in android ListView?

开发者 https://www.devze.com 2022-12-24 19:09 出处:网络
i want have an image and i want to set it as a background of android lis开发者_如何学Got view i have used android:background=\"drawable/image\"but nothing happened

i want have an image and i want to set it as a background of android lis开发者_如何学Got view

i have used android:background="drawable/image" but nothing happened

can any one guide me how to achieve this?

any help would be appricated.


Perhops

android:background="@drawable/image"

noticing the @

Also make sure your project's res/drawable folder contains a valid image file called image.jpg or image.png.


Adding to Jim, clean or re-open the project to ensure your newly added image file gets reflected in the /res/drawable folder

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号