-3

I referred example from the below link to do my android project[enter link description here][1]

[1]:

https://www.tutorialspoint.com/android/android_autocompletetextview_control.htm

Markus Kauppinen
  • 3,025
  • 4
  • 20
  • 30
Nik
  • 1
  • 1
  • Can you please add your XML layout configuration and Java code ? – tec Mar 14 '19 at 10:28
  • This is my array that is passed to autocompletetextview private String[] employee= new String[]{"20,nik", "21,ram","22,sid"}; – Nik Mar 14 '19 at 10:42
  • Please can you help me to sort this issue@tomyforever. – Nik Mar 14 '19 at 11:12
  • Edit your question, copy and paste your code. Nobody can see the error if there is no code to read. – tec Mar 14 '19 at 12:13
  • our code is working fine when we pass an array list containing only string value to autocompletetextview . but when we pass string with integer(Example city,pincode(int value)) to the autocomplete adapter it showing suggestion only if we type an string(city name) but if enter integer(pincode) we will not get suggestion. – Nik Mar 14 '19 at 13:01
  • I tried a lot to add code but unable to do it .So please check the link i have sent and only change in code is array is changed to private String[] employee= new String[]{"20,nik", "21,ram","22,sid"}; – Nik Mar 14 '19 at 13:10

1 Answers1

0

but when we pass string with integer(Example city,pincode(int value)) to the autocomplete adapter it showing suggestion only if we type an string(city name) but if enter integer(pincode) we will not get suggestion

So don't work with integers, but strings.

I guess you want a better wildcard for matching the user input. Follow this post

And please read How to ask a good question

tec
  • 999
  • 3
  • 18
  • 40