If possible, with AutoID custom views, the ability to have a getter that will return the BANano generated AutoID value for the element. This can help to assign events to the element later on.
Can you give me an example why you would need that? If the event is defined in the custom view the event will stll be raised on the original name. You can then just use the ID property to find out on which element the event was raised.
From your demo 01, e.g. original name was divchild4 with event click:
B4X:
Private Sub divchild4_Click (e As BANanoEvent)
Dim elem As SHIonBaseElement = Sender
Log(elem.ID) ' <------ the auto generated ID e.g. afgdrpgh_4
Log(e)
End Sub
If mName.EqualsIgnoreCase("lblAssign") Then
Log($"Element...${mName}"$)
Log(mElement)
End If
The latter does not get executed for the AutoID elements. Perhaps if possible to have a way to re-assign the element and I thought perhaps getting the new id would just help one to re-initialize it or something.
This is expected behaviour. As described in the AutoID property: 'Overrides the ID/Name with a random string. If true, you CANNOT use it in your code!'
So trying to do something like lblTop.Text = ... where lblTop has an AutoID will not work.
Ok. I will think of a better way to do this. I need to update some components in realtime and it could be the same layout for multiple records. Let me re-read on the loadlayoutarray stuff. Im surely missing something.