0

I am trying to create calculator application in Android Studio using Java, I have EditText for showing result. When I focus this input Keyboard is showing. But I don't want to see keyboard in focus event as in normal calculator. Is there any way to solve this, or can I use other element either than EditText, I have used getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN); in OnCreate method, but it doesn't work

m10
  • 15
  • 1
  • 5

1 Answers1

0

EditText is desired to.. edit text. do you want to allow user for editing result?

if not just replace EditText with TextView and then any keyboard won't show up

if you still want this field to be editable then take a look a THIS QA, you will find there plenty of methods for blocking keyboard pop up automatically

snachmsm
  • 17,866
  • 3
  • 32
  • 74