Android Question custom list view Error

aligol

Member
For i=1 To 80
Dim n As B4XView = xui.CreatePanel("mm")
n.SetLayoutAnimated(0,0,0,100%x,40dip)
n.LoadLayout("L_items_unit")
Label1.Text="unite"& i
clv_units.Add(n,"")

Next
I wrote a code a while ago and that worked perfectly , but now it gives me this error. I'm new and don't know where is this problem occur and how solve that. I'll be appreciate if some one help me.
 

Mahares

Expert
Licensed User
Longtime User
best to share the project.
I'll be appreciate if some one help me
Theoretically, your code looks perfect although it looks better if you use code tags. See below:
B4X:
For i=1 To 80
        Dim n As B4XView = XUI.CreatePanel("mm")
        n.SetLayoutAnimated(0,0,0,100%x,40dip)
        n.LoadLayout("L_items_unit")
        Label1.Text="unite"& i
        clv_units.Add(n,"")
    Next
The error is somewhere else, not in this code. As the powerhouse Alexander suggested.: Attach your project reproducing the error or post a lot more relevant code.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…