Weird searching with c1Combo AutoComplete with MatchEntry Extended

Posted by: softcomlimited on 25 November 2019, 5:51 pm EST

    • Post Options:
    • Link

    Posted 25 November 2019, 5:51 pm EST

    Hello,

    I am using c1FlexGrid v4.0.20151.38.

    In my grid I have a column for GLAcNo and a 2nd for GLAcName.

    I create two c1Combos and use them as the editors.

    Dim c1cboAcNo As New C1.Win.C1List.C1Combo

    Dim c1cboGLAcName As New C1.Win.C1List.C1Combo

    Me.Controls.Add(c1cboAcNo)

    With c1cboAcNo

    .DataSource = GLAcNoList.DataSource

    .DisplayMember = “GLAcNo”

    .DataMember = “GLAcNo”

    .ComboStyle = C1.Win.C1List.ComboStyleEnum.DropdownCombo

    .LimitToList = False

    .AutoCompletion = True

    .MatchEntry = C1.Win.C1List.MatchEntryEnum.Extended

    .MatchCompare = C1.Win.C1List.MatchCompareEnum.PartiallyEqual

    .AutoDropDown = True

    End With

    Me.c1fgGLLines.Cols(“GLAcNo”).Editor = c1cboAcNo

    Me.Controls.Add(c1cboGLAcName)

    With c1cboGLAcName

    .DataSource = GLNameList.DataSource

    .DisplayMember = “GLAcName”

    .DataMember = “GLAcName”

    .ComboStyle = C1.Win.C1List.ComboStyleEnum.DropdownCombo

    .LimitToList = False

    .AutoCompletion = True

    .MatchEntry = C1.Win.C1List.MatchEntryEnum.Extended

    .MatchCompare = C1.Win.C1List.MatchCompareEnum.PartiallyEqual

    .AutoDropDown = True

    End With

    Me.c1fgGLLines.Cols(“GLAcName”).Editor = c1cboGLAcName

    GLNameList and GLAcNoList are two ordinary lists List(Of GLAc) and a GLAc is simply GLAcNo As String and GLAcName As String. Both lists have exactly the same items except GLNameList is sorted by GLAcName and the other is sorted by GLAcNo.

    If you type say “R” in the GLAcName combo it highlights the middle of the name so that you cannot do a progressive search properly. However the AcNo combo seems to work ok. I cannot figure out why.

    Please see attached demo.

    Regards

    BrianC1ComboTest.zip

  • Posted 26 November 2019, 7:09 am EST

    Hello,

    Sorry but we could not replicate the issue at our end with your mentioned builds and progressive search works properly.

    We have created a stripped down sample as per your attached sample. Kindly modify it accordingly to replicate the issue so that we can provide you a helpful solution.

    Note : Place the attached database file on the following path then run the sample : …\Documents\ComponentOne Samples\Common



    Regards,

    Prabhat Sharma.

    ComboAutoCompleteDemo.zip

  • Posted 26 November 2019, 8:48 am EST

    Mr Sharma,

    Thank you for your response.

    Your example works as expected. I had started with a similar example which is why I am baffled.

    I even adjusted your your example to have multiple columns in the combo and it still worked.

    I went back to my sample and swapped out the lists for datatables and it worked!

    The problem seems to be the lists.

    Thanks for the insight.

    Regards

    Brian

  • Posted 26 November 2019, 9:07 am EST - Updated 4 October 2022, 12:29 am EST

    Mr Sharma,

    I spoke too soon, this is still something happening when you type “R”.

    Please see attached.

    Regards

    Brian

    ComboAutoCompleteDemo.zip

  • Posted 26 November 2019, 4:25 pm EST

    Mr Sharma,

    The items that seem to behave oddly are those that have the letter appearing more than once in the words. If you type “R” you cannot type “e”, “t” to get the “Retirement” without first backspacing to the first “e”. Is it supposed to be like that? All other implementations I’ve come across work so that you can progressively type R, e, t.

    Regards

    Brian

  • Posted 27 November 2019, 2:32 am EST

    Hello,

    We too can replicate the issue in your mentioned builds i.e. v4.0.20151.38. Please see the attached gif “oldBuilds.gif”.

    When typing ‘r’ it searches first all the words started from “R” then put the cursor on the first word where “r” founds means does not ignore character case.

    As a workaround if you want to search words from ‘r’ from the first letter, type “R” in upper case then type ‘e’ and ‘t’ to get “Retirement”.

    It was a bug that gets fixed in the earlier builds. Please see the attached gif “latestBuilds.gif”.

    Regards,

    Prabhat Sharma.

    demo.zip

  • Posted 27 November 2019, 7:59 am EST

    OK, so when I upgrade next year it will get solved.

    Thanks for the help

    Regards

    Brian.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels