Android Question How to change listview segmentation line color

Ohanian

Active Member
Licensed User
Longtime User
Hello,

use this function :

B4X:
Sub SetDivider(lv As ListView, Color As Int, Height As Int)
    Dim r As Reflector
    r.Target = lv
    Dim CD As ColorDrawable
    CD.Initialize(Color, 0)
    r.RunMethod4("setDivider", Array As Object(CD), Array As String("android.graphics.drawable.Drawable"))
    r.RunMethod2("setDividerHeight", Height, "java.lang.int")
End Sub
 
Upvote 0

a552191386

New Member
thanks very much
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…