last day (14 days later) » 

1:03 PM
1
Q: How to make custom filter in android using base adapter?

ShrutiCan you please tell me how to make custom filter in android using base adapter ? I have made a simple demo of auto complete. I take array of string in which there is 2250 entries with Name and code like that example "Alexandra Palace-(AAP)", first name is given and the it code inside the bracket....

 
You haven't doing any filter operations in your filter class
 
that I need to aad ..do you HAVE ANY IDEA.I don't know from where I will start ..
 
@Shruthi have checked this stackoverflow.com/questions/19122848/… if you dont understand then i will give you full code
 
@kalyanpvs I understand but could u please give whole code
@kalyanpvs can you please tie you id will send my code
 
@Shrithi ok..send your code to pvskalyan580@gmail.com
 
1:03 PM
@kalyanpvs please check mail
 
@Shruthi ok..i will check
 
@kalyanpvs did you get any solution..?
 
@Shruti yeah...wait i will post
@Shruti some of them have two brackets..what about that??
 
I didn't get..can you please elaborate which bracket you are saying ?
Hi
Sir
you are saying "Milford (Surrey)-(MLF)",
this ...
Actully it name "Milford (Surrey)",
code is "(MLF)",
 
ok...
hi
 
1:04 PM
if user search mlf then gives "Milford (Surrey)-(MLF)",
Hello sir
 
now i get it
 
Actually I got web service of station name and station code..
but due to performance I hardcoded the station name and code and put in String array
in this format name-(code)
just need to filter using code not by name
but default autocomple filter the staring character
 
yeah its done
 
that why i go for custom
thanks sir
 
but its some what slow because we need to check for the 2500 items
 
1:08 PM
yes I understant
it fine
 
please post your anser
 
here is the link of code
copy code from the pasterbin
 
ok thanks ir
checking
 
ok..
shall i need to post it as answer??
 
1:13 PM
wait sir immolator running
you post
your anwser
 
ok
Have you tested??
is it working or any issue??
Before that remove this line for Autocompletetextview in xml file
android:text="AutoCompleteTextView"
And this one also for better perfomance of AutocompleteTextview
autocompleteView.setThreshold(2);
 

last day (14 days later) »