Why can't a specific text box / search string initiate a search when sending search or input codes?
- Is there a search key on the Android keyboard with the Enter key with metastat? Or is it a completely different key?
- What is a search key metastat? Or is it his own key code?
- Does Android key code
KEYCODE_ENTERinclude a search key? Or KEYCODE_SEARCH?
I had the same problem as this guy and came up with a fix (below): Failed to press the Search button (magnifying glass) on the Android keyboard using Appium / Selenium / Java .
While my question is related to the fact that I have a question , what is the metastat of the search key on the Android keyboard, and why doesn’t it work KEYCODE_ENTER? Why doesn’t work KEYCODE_SEARCH? I don’t care about how to fix it, and why this is happening (so that I can fix it myself).
I am trying to interact with the application via adb using the / appium command line:
adb shell input keyevent KEYCODE_ENTERadb shell input keyevent KEYCODE_SEARCH
Example
Take the Google search bar widget for example. What exactly happens with the enter key to turn it into a magnifying glass? I am a black box tester, so I do not get access to the code I'm working with.
Follow these steps to find out what I'm talking about:
- Click on the Google search bar to focus on the field and bring up a soft keyboard.
- , Google , .
- "" ( ).
adb shell input keyevent KEYCODE_SEARCH- , . , .
adb shell input keyevent KEYCODE_ENTER- , , , .
, , , KEYCODE_ENTER, , KeyEventListener KEYCODE_ENTER , Google, ?
?
, ( , ), , KeyEventListener KEYCODE_ENTER. KeyEventListener , KEYCODE_ENTER ? KEYCODE_SEARCH?
:
, , .



