Setting a default cursor at the Entry text field in xamarin form and hide the keyboard

Thuy Phan 1 Reputation point
2022-06-30T13:01:52.557+00:00

Hi all, I am working on the Scanner project (Zebra machine) so that whenever I scan a barcode into the Entry, the information is filled in the Entry. However, for the android application, we have to tap on the entry in order to enter the information. Is there a way that I can set a default cursor at the Entry so that whenever I scan the barcode, the information is there. I was using the Entryname.focus(), but all it does is that bold the field that I have to enter.

Also, is there an effective way to hide the keyboard for the in the app, as I will just make the cursor jump to all required filled Entry.

Thank you:)

Not Monitored
Not Monitored
Tag not monitored by Microsoft.
35,985 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. BendJava 1 Reputation point
    2022-06-30T14:43:16.957+00:00

    I think I used to code:

    public class ExerciseQrCode extends javax.swing.JFrame {

     String qrCodeData;  
     String filePath = "QRCode.png";  
     String charset = "UTF-8"; // or "ISO-8859-1"  
     File imageFile =null;  
    

    bacaberita to keep practicing and find the solution.