views:

96

answers:

1

Hi guys, my question is kinda related to this question: http://stackoverflow.com/questions/3216169/numeric-soft-keyboard-on-android

BUT, the question above isnt answered, so here i am.

Theres a EditText that when it gets touched or has focus, i want the Software Keyboard to show up by default as NUMERIC! Of course, you can switch back to ALPHANUMERIC, but i want to force it to show up as NUMERIC.

Thanks guys

+1  A: 

Use the android:inputType XML attribute with the number value:

<EditText android:id="@+id/edtInput"
    android:layout_width="0dip"
    android:layout_height="wrap_content"
    android:inputType="number"/>
Cristian
I'm gonna try it! Thank you Cristian!
Philipz
Hey man, it worked! Thank you again man! Accepted :)
Philipz