BindingSource.Find Question

  • Thread starter Thread starter Alexander Loose
  • Start date Start date
A

Alexander Loose

Hello,

I am using the BindingSource.Find-Methode to find an Item in my
BindingSource. This works fine to find the exact pattern, but now I
search for a fuzzy finding method.

For example:

XXX34234234
DDD4324543
HAM5454545
MUC6456566

I want to do a fuzzy search for "HAM" .

therefore I sort the bindingsource and the I perform the
BindingSource.Find Method.
I also tried it with * or % patterns.

Does anyone know a way to do fuzzy/unexact find/search operations in a
BindingSource

Best regards from Germany

Alexander Loose
 
Unfortunatley, there is nothing like the old 'seek' method. So, depending on
how many records are in your source, either linear search for the first '>='
or code a binary search. Also, I would sugest using the underlying
'DataView' to do the search.
 
Back
Top