Android EditText default numeric keyboard and allow text [duplicate]

◇◆丶佛笑我妖孽 提交于 2019-12-04 04:58:59

I just tried to add a number text field in Android and it ran in the emulator fine. It defaults to bring up the number pad first, but you can switch to characters just as easy. So try to use a number text field.

<EditText
    android:id="@+id/editText1"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:inputType="number" />
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!