Attached you find a project where the buttons are added in the code, which is much easier.
The Buttons are in an array.
You should verify the characters in the buttons, I put them in a string array to add them easily to the buttons.
I added a new empty panel for the buttons, but I left the original one with the buttons in the layout file, renamed it to pnlAlpha1 and set it to invisible and. You should remove it after testing.
This is the code to add the buttons:
Sub InitButtons
Dim Row, Col, i As Int
pnlAlpha.Top = 36%y
pnlAlpha.Height = 64%y
For Row = 0 To RowNb - 1
For Col = 0 To ColNb - 1
i = Row * ColNb + Col
Buttons(i).Initialize("btnAlpha")
pnlAlpha.AddView(Buttons(i), Col * btnWidth, Row * btnHeight, btnWidth, btnHeight)
Buttons(i).Text = btnText(i)
Buttons(i).Tag = i + 1
Buttons(i).TextSize = 28
Buttons(i).Typeface = Typeface.DEFAULT_BOLD
Next
Next
End Sub
You see the other modification in the files below.
As the whole zip file is too big I post only the changed files.
You must rename ThaiLeseTrainer.txt to ThaiLeseTrainer.b4a.