Hi,
I have a panel with 15 EditText and I want to set a custom filter for the keyboard. So instead of manually written for every EditText I just write a method which should solve my purpose but unfortunately it's not working at all!! I really don't understand where is mistake.
Would someone help me in this regards.
Thanks in advance.
I have a panel with 15 EditText and I want to set a custom filter for the keyboard. So instead of manually written for every EditText I just write a method which should solve my purpose but unfortunately it's not working at all!! I really don't understand where is mistake.
Would someone help me in this regards.
Thanks in advance.
B4X:
Public Sub RemoveSpecialChar(srcPanel As Panel)
Dim kb As IME
Dim answ As Int
'srcPanel.Initialize("")
For answ=0 To srcPanel.NumberOfViews-1
If srcPanel.GetView(answ) Is EditText Then
Dim txt As EditText
txt=srcPanel.GetView(answ)
If txt.InputType = txt.INPUT_TYPE_TEXT Then
kb.Initialize("")
kb.SetCustomFilter(txt, txt.INPUT_TYPE_TEXT, "QWERTYUIOPASDFGHJKLZXCVBNMqwertyuiopasdfghjklzxcvbnm1234567890 ")
End If
End If
Next
End Sub