You have a few options, one is for example, to set each panel tag propertie and in give every panel the same click event, then in the click event, use the sender keyword
like
B4X:
dim p as panel = sender
log("panel " & p.tag & " was clicked")
Okay, after some thought, I will change the above functionality.
Within each Panel, I have a Label, the text within the represents the day of the month.
So, instead of using the panel_Click event, I will use the label_Click event and read the text from the Label.
Using advice from Cableguy, I have:
Sub Globals:
Like so:
lblP1.Initialize("calLabels")
To
lblP42.Initialize("calLabels")
I tried this initially just to get it working, but Click event is not fired.
Also, all Labels are not populated.
I have attached my project.