I want to know 2 things
how to always show soft keyboard and do not let it be closed ( even when back or OK button was pressed ) ?
and how can I get an input from it?
I have already tried this code:
EditText yourEditText= (EditText) findViewById(R.id.ed);
InputMethodManager imm = (InputMethodManager) getSystemService(INPUT_METHOD_SERVICE);
with these variants:
imm.showSoftInput(yourEditText, InputMethodManager.SHOW_IMPLICIT);imm.toggleSoftInputFromWindow( yourEditText.getApplicationWindowToken(), InputMethodManager.SHOW_FORCED, 0);imm.showSoftInput(yourEditText, InputMethodManager.SHOW_IMPLICIT);
Use
android:windowSoftInputMode="stateAlwaysVisible"in toAndroidManifest.xmlfileLike this:
If you want to still open
Keyboadafter use done any operation then do this via programeticallyOR
To Show Soft Keyboard
OR
EDITABLE_VIEWcan be any view which has focus on screen likeOR
Documentation