J junaidahmed Well-Known Member Licensed User Longtime User Jun 12, 2018 #1 I have an EditText with some Value,I would like to know to clear EditText When Scanning from external Barcode device...
I have an EditText with some Value,I would like to know to clear EditText When Scanning from external Barcode device...
DonManfred Expert Licensed User Longtime User Jun 12, 2018 #2 Other apps (the barcodescanner) does not have the rights to change values in your app. If you got the barcode sended to the edittext it is up to YOU to clear the edit to get the next barcode. Upvote 0
Other apps (the barcodescanner) does not have the rights to change values in your app. If you got the barcode sended to the edittext it is up to YOU to clear the edit to get the next barcode.
MarkusR Well-Known Member Licensed User Longtime User Jun 12, 2018 #3 if u have a Barcode reader as keyboard simulation (ex via Bluetooth connected), normal it send a line break char (return) so u need process this text after the device simulate the enter key and then set the text property to empty string. Upvote 0
if u have a Barcode reader as keyboard simulation (ex via Bluetooth connected), normal it send a line break char (return) so u need process this text after the device simulate the enter key and then set the text property to empty string.
Bladimir Silva Toro Active Member Licensed User Longtime User Jun 12, 2018 #4 Hello what I use to know if there is any value in the EditText is: B4X: Sub TxtBarCode_FocusChanged (HasFocus As Boolean) If TxtBarCode.Text.Length>=1 Then SearchPCod(TxtBarCode.Text) End If End Sub To clean the EditText in the SearchPCod function if it does not find the product is: B4X: ToastMessageShow("Product "&TxtBarCode.Text&" Does not exist",True) TxtBarCode.Text ="" TxtBarCode.RequestFocus I use a barcode reader connected by Bluetooth Upvote 0
Hello what I use to know if there is any value in the EditText is: B4X: Sub TxtBarCode_FocusChanged (HasFocus As Boolean) If TxtBarCode.Text.Length>=1 Then SearchPCod(TxtBarCode.Text) End If End Sub To clean the EditText in the SearchPCod function if it does not find the product is: B4X: ToastMessageShow("Product "&TxtBarCode.Text&" Does not exist",True) TxtBarCode.Text ="" TxtBarCode.RequestFocus I use a barcode reader connected by Bluetooth