My main activity code:
// here you put all your data.
String[] dataArray = { \"Amit sharma Kumar\", \"Hisham Kumar Munner\",
\"Vineet John Chaturvedi
First of all, you don't need TextWatcher with AutoCompleteTextView because AutoCompleteTextView has its own method to watch text i.e. MyWatcher. You need to use :
setThreshold(3);
final String[] AndroidDesk= getResources().getStringArray(R.array.clothname_arrays);
ArrayAdapter My_arr_adapter= new ArrayAdapter(getApplicationContext(),
android.R.layout.simple_dropdown_item_1line,AndroidDesk);
cloths.setThreshold(1);
cloths.setAdapter(My_arr_adapter);
cloths.setOnItemClickListener(new OnItemClickListener() {
public void onItemClick(AdapterView> arg0, View arg1, int arg2,long arg3) {
}
});