Hi
I’m trying to create a panel that will contain buttons added by user.
Before I go any farther I’d like to know if it is possible to allow end-user to name new created buttons and add a numerical value to it (which both will be displayed as a text and store in SQL database)?
Thank You
I’m trying to create a panel that will contain buttons added by user.
Before I go any farther I’d like to know if it is possible to allow end-user to name new created buttons and add a numerical value to it (which both will be displayed as a text and store in SQL database)?
Thank You
B4X:
Sub Add_Button_Click
Dim btn(10) As Button
number = number + 1
btn(number).Initialize("button")
'Msgbox("Button Added", "Success")
Panel1.AddView(btn(number), Button1.Left, toppos, Button1.Width, Button1.Height)
Panel1.Invalidate
btn(number).BringToFront
btn(number).Color = Colors.Green
btn(number).Visible = True
btn(number).Text = (" Custom : " & (number))
btn(number).TextSize = 25dip
btn(number).Enabled = True
btn(number).TextColor = Colors.Blue
btn(number).Tag = number
Panel1.Height = toppos + 13%x
Panel1.Invalidate
ScrollView1.Panel.Height = Panel1.Height
toppos = toppos + 11%x
End Sub
Sub button_click
Dim b As Button
b = Sender
Msgbox("Button Clicked" , b.tag)
End Sub