1

I ran into a situation where a virtual keyboard displayed

1) When setting the listener:

rssURLTV = (TextView) findViewById(R.id.rssURL);

        rssURLTV.setOnClickListener(new View.OnClickListener() {

            // @Override
            public void onClick(View v) {

                feedUrl = (String) rssURLTV.getText().toString();

                Intent intent = new Intent("urss.database_table");
                startActivity(intent);

            }
        });

2) and activity started ....

for these situations, I do not want display a virtual keyboard

Max Usanin
  • 2,479
  • 6
  • 40
  • 70

2 Answers2

3

You can try putting

<activity android:name=".Main"
          android:label="@string/app_name"
          android:windowSoftInputMode="stateHidden"
          >

in the android manifest

Niall C.
  • 10,878
  • 7
  • 69
  • 61
Mark Hetherington
  • 1,612
  • 14
  • 24
0

try this for hiding virtual keyboard in Current Activity:

getWindow().setSoftInputMode(
WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN);
ρяσѕρєя K
  • 132,198
  • 53
  • 198
  • 213