Hello friends, how can we fill the dynamic buttons text from sql database values? For example we have got values (milk, chocolate, orange, melon ...) in database column, how can we generate (horizontal rows and vertical rows) dynamic buttons text with database values.
Getting from database:
Dim Cursor As JdbcResultSet
Cursor =connect.sql1.ExecQuery("select product from stock order by product asc")
Cursor.Close
This one is generates dynamic buttons (horizontal rows and vertical rows) from MarkusR thank you.
For x = 0 To 3
For y = 0 To 10
Dim btn1 As Button
Dim PosX As Pos
PosX.x = x
PosX.y = y
btn1.Initialize("Button")
btn1.Text=**product name**
ScrollView1.Panel.AddView(btn1,x*25%x,y*15%y,100dip,100dip)
Next
Next
How can we combine properly these two different cases same like the picture
Thanks in advance
Getting from database:
Dim Cursor As JdbcResultSet
Cursor =connect.sql1.ExecQuery("select product from stock order by product asc")
Cursor.Close
This one is generates dynamic buttons (horizontal rows and vertical rows) from MarkusR thank you.
For x = 0 To 3
For y = 0 To 10
Dim btn1 As Button
Dim PosX As Pos
PosX.x = x
PosX.y = y
btn1.Initialize("Button")
btn1.Text=**product name**
ScrollView1.Panel.AddView(btn1,x*25%x,y*15%y,100dip,100dip)
Next
Next
How can we combine properly these two different cases same like the picture
Thanks in advance