Android Question EditText_EnterPressed different for soft and hard keyboards

pfhrr

Member
Licensed User
I have code that has three edittext views.

With soft keyboard after entering text in EditText3, when Finished is pressed the code executes as expected;
  • all text is cleared
  • focus shifts to EditText1.

With a Bluetooth connected external hard keyboard after entering text in EditText3, when Return is pressed the following occurs;
  • all text is cleared
  • focus shifts to EditText1 briefly then
  • focus shifts to EditTest2

Sub EditText3_EnterPressed

EditText1.Text = "" ' clear input
EditText2.Text = "" ' clear input
EditText3.Text = "" ' clear input

EditText1.RequestFocus ' shift focus back to first EditText view

End Sub
 

Attachments

pfhrr

Member
Licensed User
Thanks Erel

I tried your code but still get the same result - focus moves to EditText1.Text with soft keyboard, but focus moves to EditText1.Text briefly then EditText2.Text with external keyboard.
 
Top