Android Onclicking textView the editText comes without numpad.How to get the numpad on single click on textView?
<p>I have a textview.On clicking the texstview the edit text comes up with focus. But to get the numpad another click is required.</p>

<p>I want that when i click on TextView,the edit text should come up with the numpad togeter withoutanother click on the editText.Not through xml.But manually
In the xml i have already given it as android:inputType="number"
(the text view is made invisible on click)</p>

<p>The on click method----
case R.id.txtPhoneNo:   </p>

<pre><code>        hintPhoneNum.setVisibility(View.VISIBLE);
        phoneNum.setVisibility(View.GONE);
        edtPhoneNum.setVisibility(View.VISIBLE);
        edtPhoneNum.requestFocus();
        edtPhoneNum.setText("");
</code></pre>

<p>WHen the editText gets focus how to get the numpad forcefully?</p>

<p>The correct answer is 
    InputMethodManager imm = (InputMethodManager)getSystemService(
                      Context.INPUT_METHOD_SERVICE);
            imm.toggleSoftInput(0, InputMethodManager.SHOW_IMPLICIT);</p>
