Android Question Question on IME.SetFilterLength

jzfla01

Member
Licensed User
Longtime User
In the SUB Globals, I have this:

DIM IME as IME

In the Activity_Create module:

Activity.LoadLayout ("DBase")
IME.SetLengthFilter (txtDept, 2) 'Set Max Length for txtDept = 2
IME.SetLengthFilter (txtDept, 25) 'Set Max Length for txtDeptName = 25

DBASE is a Designer created page with a text box named txtDept and txtDeptName on it.
Both txtDept and txtDeptName are defined as INPUT TYPE = TEXT

When the application runs, I would expect that I could only enter up to 2 characters in the field txtDept, but on the screen, I can enter as many as I like to enter.

I am testing using the emulator.

Should the IME.SetLengthFilter be placed in a different area of code to allow the user to only enter two characters?

Thank you very much!

John
 

jzfla01

Member
Licensed User
Longtime User
Something must have gotten goofed up with the layout. I opened the IME example and it worked there. I deleted the two EDITTEXT boxes in the layout designer and recreated them, now they work as expected.
 
Upvote 0
Top