How to filter a large list in a combobox to limit the displayed entries?

In this discussion, let's say we have a combobox with the numbers from 15 to 195. (In fact it could go much higher)

It would be tedious to scroll thru such a list to find the one that you want.


What we would like to see:

When we tap the combobox, a keyboard appears.

When we start typing, the enties in the combobox are filtered - only displaying the entries that match the filter.


What we are seeing:

When we tap the combobox, a keyboard appears.

When we start typing, the combobox jumps to the first entry that starts with that number. But we can still scroll up or down past the valid numbers.

What our users want, is if they type in 42, then only 42 will be in the list (based on our current example).

Also, what we see is after entering a number, say 3, the combobox jumps to 30 and then if I tap on a number, say 32, nothing happens.


Thanks for looking at this.


3 Replies

VV Vijayakumar Viswanathan Syncfusion Team July 21, 2022 10:55 AM UTC

Hi Will,


Query: When we start typing, the entries in the Combobox to be filtered and need to display the entries that match the filter.


In the SfComboBox, we have the AllowFiltering property is used for filtering the items based on the input entries. We have prepared a sample using the AllowFiltering property for your reference. Please get the sample from the attachment.


Please let us know if you need any other details.


Regards

Vijayakumar V


Attachment: ComboBoxSample_e3beae11.zip


WA Will Autio July 21, 2022 09:52 PM UTC

Hello  Vijayakumar V,

Thanks for the reply and the sample code. Of course it worked just fine. By comparing it to mine I could figure out what was different and eventually get mine to work.

Regards,

Will



RS Ruba Shanmugam Syncfusion Team July 22, 2022 05:56 AM UTC

Hi Will,


We are glad to hear that the suggested solution works for you. Please let us know if you need any other details.


Regards,

Ruba Shanmugam


Loader.
Up arrow icon