android - Duplicate value issue in MultiAutoCompleteTextView -
i new android development , using multiautocompletetextview in app , following code.
public textview autoselected; string[] countries = {"india","usa","canada","indonesia","belgium", "france", "italy", "germany", "spain"}; @override protected void oncreate(bundle savedinstancestate) { super.oncreate(savedinstancestate); setcontentview(r.layout.activity_main); multiautocompletetextview autocompletetextview = (multiautocompletetextview)findviewbyid(r.id.autocompletetextview); arrayadapter<string> adapter = new arrayadapter<string>(this,android.r.layout.simple_dropdown_item_1line,countries); autocompletetextview.setadapter(adapter); autocompletetextview.settokenizer(new multiautocompletetextview.commatokenizer()); }
first problem , main problem textview getting duplicate values means same country showing in textview again , again. example: can select usa autocomplete n number of times , showing n times in text field.
i want if selected specific value suggestion, in case either should not visible in suggestions or should not visible in textview.
second issue
i want customize design of selected values in textview background , close sign attached it.
Comments
Post a Comment