Hi all,
I have app that use bluetooth barcode reader - set as a HID.
On my layout, there are 3 object :
1) txt1 - Edit Text
2) txt2 - Edit Text
3) btn1 - Button
I want to put cursor always on txt2 after do the scan, so this the code in txt2
When cursor placed in txt2, after the scan, something strange happen with cursor.
If i put this code on Activity_Create
Cursor jump to txt1.
change code on Activity_Create to
Cursor disappear, and while cursor not visible, do the scan again, raised clicked event in btn1.
It seem that the barcode sent twice Enter/Tab keys. Can someone help me to fix this?
Thanks in advance.
I have app that use bluetooth barcode reader - set as a HID.
On my layout, there are 3 object :
1) txt1 - Edit Text
2) txt2 - Edit Text
3) btn1 - Button
I want to put cursor always on txt2 after do the scan, so this the code in txt2
B4X:
Sub txt2_EnterPressed
If(txt2.Text = "") Then Return
txt2.Text = ""
txt2.RequestFocus
End Sub
When cursor placed in txt2, after the scan, something strange happen with cursor.
If i put this code on Activity_Create
B4X:
FieldOrder.Initialize(Array As Object(txt1,txt2),True)
change code on Activity_Create to
B4X:
FieldOrder.Initialize(Array As Object(txt1,txt2),False)
It seem that the barcode sent twice Enter/Tab keys. Can someone help me to fix this?
Thanks in advance.