0
I want my TextView
only accepted as input numbers, but the line android:numeric="decimal"
does not effect, it still allows me to type letters.
0
I want my TextView
only accepted as input numbers, but the line android:numeric="decimal"
does not effect, it still allows me to type letters.
4
To allow only numbers you must set inside your EditText
in this way :
android:inputType="number"
Another way would be :
<EditText android:id="@+id/myNumber"
android:digits="0123456789."
android:inputType="numberDecimal"/>
Browser other questions tagged android eclipse textview
You are not signed in. Login or sign up in order to post.
It didn’t work either
– DaniloAlbergardi
How’s your xml? @Daniloalbergardi
– Wellington Avelino
<Textview android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="Enter Second number" android:inputType="number" />
– DaniloAlbergardi
This is inside an editText ? @Daniloalbergardi
– Wellington Avelino
kkkk puts me sorry, was putting in the text, was in Edit, Thanks!
– DaniloAlbergardi
if the answer was satisfactory, mark as right to help other users. @Daniloalbergardi
– Wellington Avelino