Hellow all
Kindly, iam wondering , why this is not working, and how to make it work
Main Activity:
My Class:
https://www.dropbox.com/s/5p90qag03lmwna0/Error.png?dl=0
Kindly, iam wondering , why this is not working, and how to make it work
Main Activity:
B4X:
Public Sub GetMainIv(prodId As Int) As ImageView
Return Page(CurrentPage).MainProduct(prodId).MyImage
End Sub
Public Sub GetMainLv(prodId As Int) As Label
Return Page(CurrentPage).MainProduct(prodId).MyLable
End Sub
Private Sub GetMainColum(prodId As Int) As Int
Return Page(CurrentPage).MainProduct(prodId).ProdColumn
End Sub
Public Sub GetMainRow(prodId As Int) As Int
Return Page(CurrentPage).MainProduct(prodId).ProdRow
End Sub
My Class:
B4X:
Private Sub AddMainProducts
Private Column,Row As Int
Private ImV As ImageView:ImV.Initialize("ImV")
Private Lv As Label:Lv.Initialize
For i=0 To MainProductList.Size-1
ImV=CallSub2(ParentObject,"GetMainIv",MainProductList.Get(i))
Lv=CallSub2(ParentObject,"GetMainLv",MainProductList.Get(i))
Column=CallSub2(ParentObject,"GetMainColum",MainProductList.Get(i))
Row=CallSub2(ParentObject,"GetMainRow",MainProductList.Get(i))
ScrlPage.Panel.AddView (ImV,Column,Row ,33%x,33%x)
ScrlPage.Panel.AddView (Lv,Column,Row+33%x,33%x ,22%x)
Next
End Sub
https://www.dropbox.com/s/5p90qag03lmwna0/Error.png?dl=0