I\'m trying to deactivate the soft keyboard when using a NumberPicker to enter numerical values (for aesthetic reasons). This is my layout-xml-code:
The simplest I found to work was :
numberPicker = (NumberPicker) myDialogView.findViewById(R.id.myViewId); EditText numberPickerChild = (EditText) numberPicker.getChildAt(0); numberPickerChild.setFocusable(false); numberPickerChild.setInputType(InputType.TYPE_NULL);