androidkeycode

Access the next button event android


I don't know if it's very clear, but i'm trying to do something when the "next" (bottom right corner of the keyboard) is pressed, and i can't find its keycode. I have tried to look for "next" or "enter" in the keycodes but nothing really relevant... does anyone know?

(actually, i've found the enter keycode to be precise, but it does not do anything)


Solution

  • Call setOnEditorActionListener() on the EditText, and give that EditText a suitable android:imeActionId value and a suitable android:imeOptions value (e.g., "actionSearch"). The listener you provide to setOnEditorActionListener() will be notified when the user taps that button.