I'm trying to force the numeric keypad to show when my activity and EditText load. It seems there's a pretty straightforward answer given here and elsewhere: you say
EditText yourEditText= (EditText) findViewById(R.id.yourEditText);
InputMethodManager imm = (InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE);
imm.showSoftInput(yourEditText, InputMethodManager.SHOW_IMPLICIT);
Fine then. So I do this and I include the imports:
import android.content.Context;
import android.os.Bundle;
import android.view.inputmethod.InputMethodManager;
import android.widget.EditText;
But when we get to showSoftInput, Studio goes red and says "Cannot resolve symbol showSoftInput". Shouldn't it be getting that symbol when I import the InputMethodManager? showSoftInput doesn't seem to be deprecated or anything.
Keyboard is not opening because it needs some delay ,
Follow this code
and XML