Android Question B4XFloatTextField with InputType

so27

Active Member
Licensed User
Longtime User
Hi everybody,

is there a possibility to change the InputType in the code from a B4XFloatTextField?
I need INPUT_TYPE_PHONE.

So far, this is how I've solved it:
B4X:
txtTelefon.edittext.InputType = txtTelefon.INPUT_TYPE_PHONE

B4XFloatTextField Keyboard is set to numbers. It's supposed to be set on Phone, though.

keyboardgif.gif
 

so27

Active Member
Licensed User
Longtime User
@DonManfred has just answered this for me in the German forum. Thank you very much. The solution is:

B4X:
    Dim edtfield As EditText = bxf.TextField
    edtfield.InputType = edtfield.INPUT_TYPE_PHONE
 
Upvote 0

DonManfred

Expert
Licensed User
Longtime User
Get the native view from it and work with the native one.

B4X:
'Dim bxf As B4XFloatTextField
    ' bxf is the FloatTextfield.
    Dim edtfield As EditText = bxf.TextField
    edtfield.InputType = edtfield.INPUT_TYPE_PHONE

Edit: Sorry to forget to post this here too :D
 
Upvote 0
Top