Isn’t the idea that the system keeps proposing more refined selections as you type?
in my case it does not work as I wish. example: if I’m writing jose and I’ve only written jos, start the filtering function and only filter by jos and not by jose. I have then to erase the e and put it back on, so I can filter by the word jose
Not sure I understand your dilemma.
Surely, when you have written ‘jos’, the algorithm would suggest all the ‘jos’ and all the ‘jose’ (along with the ‘joseph’, the ‘josh’, and the ‘aljos’, since they all have ‘jos’ in them).
But the moment you enter the ‘e’, then it would suggest only those that have ‘jose’ in them, wouldn’t it?
If you don’t want the results to update automatically, you can use the With a Search Button method so that you only see your results when you have finished typing and clicked ‘search’.
How do you set this so it doesnt keep resetting the new list view?
There are several approaches to incremental search (which you want to implement)
- The list of results is updated every time the search string is changed, if there are more characters in the string, for example, more than 3 (this condition is necessary to optimize the filter). If the line is empty, then all positions are displayed.
One timer is needed to implement this algorithm.
- The list of results is updated if the user has stopped entering. To do this, you need two timers, the first to track changes in the search string, the second to fire after a specified time interval. In this case, the value of the second timer is reset if the user continues to change the line. For example, the second timer is set to fire 1 second after the search string stops changing.
This option allows you to reduce the load on the search engine, since the list does not change every time the line is changed, but it worsens the responsiveness. If the user changes the line slowly, then the search engine will constantly update the list of results. If you increase the timer by 2 seconds, then for a user with fast character entry, such a delay will cause irritation.
Record selection criteria?
- At the beginning of the line of records
- By the entry of the desired line in the record
- By the entry of each fragment of the desired line in the record
How to display filtered records?
- Show all found records
- Only output the first n-records (as when searching on Google)
- Pagination (portioned) output (displayed by n-entries in the list and the buttons “next” and “previous” - as when searching in online stores)
Which version of the search algorithm do you need?