Setting a ListView Divider in code
Posted
by deSelby
on Stack Overflow
See other posts from Stack Overflow
or by deSelby
Published on 2010-05-27T21:04:06Z
Indexed on
2010/05/27
21:11 UTC
Read the original article
Hit count: 217
android
One of my ListView's needs to be created in code. When I specify a ListView in xml, I can set a dividerHeight and assign a color to the divider.
But apparently, in code a color is not acceptable nor is pointing to a resource id. Only a Drawable is acceptable - and I haven't gotten to that chapter yet.
Can someone point me to an example of setting a ListView divider in code?
© Stack Overflow or respective owner