嘿,我正在制作一个用户有时应该写数字的应用程序。
有没有办法立即显示屏幕键盘的数字视图?那么用户不会对“百”而不是“100”吗?
非常感谢你
嘿,我正在制作一个用户有时应该写数字的应用程序。
有没有办法立即显示屏幕键盘的数字视图?那么用户不会对“百”而不是“100”吗?
非常感谢你
android:numeric="integer"
在您的编辑文本中使用它...
你也可以使用十进制,有符号
更多详情http://androidblogger.blogspot.com/2009/01/numeric-edittext-and-edittext-with-max.html
我想你想设置 TextView inputType:http://developer.android.com/reference/android/widget/TextView.html#setInputType%28int%29。
具体要求数字键盘的示例位于http://android-er.blogspot.com/2010/07/some-examples-of-inputtype-on-edittext.html
将下面的代码放入 Edittext 视图。. . .
android:numeric="integer"
android:phoneNumber="true"
如果此提示对您有帮助,请投票给我。. .