I use the following code but get no images in the customlistview.
What am I doing wrong?
What am I doing wrong?
B4X:
Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("Layout1")
For i = 0 To 10
MainList.Add(MainItem,"Main Group")
Next
End Sub
Sub MainItem As B4XView
Dim p As B4XView = xui.CreatePanel("Panel")
p.SetLayoutAnimated(0,0,0,MainList.AsView.Width,MainList.AsView.Height/4)
Dim bmp As B4XBitmap = xui.LoadBitmapResize(File.DirAssets, "1.jpg", MainList.AsView.Width,MainList.AsView.Height/4, False)
p.SetBitmap(bmp)
''p.Color = Rnd(0xff000000, 0xffffffff)
Return p
End Sub