Android Question IME SetCustomFilter How allow a line break?

Israel Gallegos

Member
Licensed User
Help me please, how I can allow type on EditText a line break
I want allow only these characters
"0123456789abcdefghijklmnñopqrstuvwxyzABCDEFGHIJKLMNÑOPQRSTUVWXYZ.,-"

and also line breaks
(B4A)
 

Attachments

  • Captura de Pantalla 2020-12-30 a la(s) 11.23.42.png
    Captura de Pantalla 2020-12-30 a la(s) 11.23.42.png
    10.4 KB · Views: 213

roumei

Active Member
Licensed User
You could try to set a custom filter to the edittext and add CRLF to your characters:
B4X:
Dim IME1 As IME
IME1.SetCustomFilter(EditText1, EditText1.INPUT_TYPE_TEXT, "0123456789abcdefghijklmnñopqrstuvwxyzABCDEFGHIJKLMNÑOPQRSTUVWXYZ.,-" & CRLF)

Please make sure that the Single Line option in the designer is not checked for the edittext.
 
Upvote 0
Top