See my thread:
https://www.b4x.com/android/forum/threads/abmaterial-universal-page-for-application-settings.131563/
I'm building a MAP site, but to the point.
Each item on the list page has a different 'id' built from a parameter: this can be the idx of the database.
E.g. for checkbox
Dim input2 As ABMCheckbox
Dim split() As String = Regex.Split("=",linie.Get(i+1))
input2.Initialize(page, "inpCheck_"&split(0), s0, False,"")
If split(1)="1" Then
input2.State=True
Else
input2.State = False
End If
page.Cell(row,1).AddComponent(input2)
In the function that handles appearing events on the page
'Sub Page_ParseEvent(Params As Map)'.
I have support for ABMCheckbox
If eventName.StartsWith("inpcheck") And eventName.Contains("clicked") Then
objekt=""
Dim split() As String = Regex.Split("_", eventName)
If split.Length > 2 Then
For i=1 To split.Length-2
objekt=objekt&"_"& split(i)
Next
objekt = objekt.SubString2(1,objekt.Length)
eventName = split(0)&"_"&split(split.Length-1)
Else
objekt = split(1)
eventName = split(0)&"_"&split(2)
End If
End If
The way it works is that it pulls from id_paramater, the parameter itself, sets it to a global variable and then calls the ABMCheckbox handler functions
Sub inpcheck_Clicked(Target As String)
Dim check As ABMCheckbox = page.Component("inpcheck_"&objekt)
If check.State Then
ChangeConfig(objekt, "1")
Else
ChangeConfig(objekt, "0")
End If
LogDebug("check - "&objekt&" "&check.State)
End Sub
In this way, you can handle any large ABMList list on the page elements within it.