Android Question add B4XFloatTextField programatically

Filipe Ferreira

Member
Licensed User
Longtime User
Hello,

is it possible to add B4XFloatTextField programatically?

i need to add and remove multiple B4XFloatTextField to a panel and i prefer not to create all of them in design view.


Create panel with B4XFloatTextField:
Try
PN_CRIA_PARCELA.Initialize("PN_CRIA_PARCELA")   
PN_CRIA_PARCELA.Color=Colors.LightGray
'**** DIMENSIONA ****
Dim LB_QTT As B4XFloatTextField
LB_QTT.Initialize(CALLBACK,"LB_QTT")
Dim ET_QTT As EditText=LB_QTT.TextField
'**** ESTILIZA ****
'**** INSERE NA LISTA ****
PN_CRIA_PARCELA.AddView(ET_QTT,1%x,10%y,40%x,10%y)
'****   
Catch
Log(LastException)
End Try
Activity.AddView(PN_CRIA_PARCELA,0%x,10%y,100%x,83%y)
 

Mahares

Expert
Licensed User
Longtime User
is it possible to add B4XFloatTextField programatically?
Maybe this example in this link will do it for you. You substitute B4XSwitch for B4XFloatTextField
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…