Search code examples
androidandroid-edittextandroid-keypad

I do not want the appearance of the writing pad, but when you press


I have a problem in Edittext, When you open the Activity , the clavier opened . I want the board not appear until you press it . example : https://i.sstatic.net/GppYS.png


Solution

  • Try adding the following line of code inside your Activity's onCreate() method.

    getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN);