I’m writing an ASP.NET MVC application and I have a form where a user can enter one or more part numbers that they used to fix a problem. Most of the time they know the part number and can just type it in. Occasionally, however, they need some extra help.
The part number table has over 50,000 items in it which is way too big for a dropdown. Also, the select takes some time so I don’t know that an autocomplete is all that great here either.
What are some other suggestions on what I can do to make this user friendly?
I would use Autocomplete box + added server side cache on part numbers (so you won’t need take them from Db each time, only when records were updated). This way it should work pretty fast.
Caching in ASP.NET with the SqlCacheDependency Class
With this jQuery peace of code you can filter letters which user inputs into your ‘Autocomplete’ box:
(replace those numbers with yours, which correspond to allowed characters. For example e.keyCode == 16 is a SHIFT key, 64 – 91 codes are letters from A to Z)