use AutocompleteTextView, set the "setTreshold ()" high and call showDropDown () when the button is clicked
code update:
String[] values = { "abc_0", "def_0", "ghi_0", "abc_1", "def_1", "ghi_1", "abc_2", "def_2", "ghi_2", "abc_3", "def_3", "ghi_3", }; final AutoCompleteTextView actv = (AutoCompleteTextView) findViewById(R.id.actv); final ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, android.R.layout.simple_dropdown_item_1line, values); actv.setAdapter(adapter); actv.setThreshold(256);
source share