android - Display contacts name and phone number in multiautocomplete textview -


i have multiautocomplete textview autocompletes when user types on box respect data query on contactscontracts using content resolver. wanted display name , number on 1 list.

here code

        name_val = (string[]) c_name.toarray(new string[c_name.size()]);         phone_val= (string[]) c_number.toarray(new string[c_name.size()]);            arrayadapter<string> adapter = new arrayadapter<string>(getactivity(),r.layout.custom_dropdown, name_val);         txtphoneno.settokenizer(new multiautocompletetextview.commatokenizer());         txtphoneno.setadapter(adapter); 

unfortunately displays name. wanted display number after the contacts name.

you should use custom adapter or simple adapter custom view


Comments

Popular posts from this blog

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -

java - JavaFX 2 slider labelFormatter not being used -