Bind multiple searching values in autocomplete box

1 Answer 112 Views
AutoCompleteBox
ajay
Top achievements
Rank 1
ajay asked on 14 Dec 2022, 09:39 AM | edited on 14 Dec 2022, 09:40 AM

   <telerik:RadAutoCompleteBox TextSearchMode="Contains" SelectedItem="{Binding Entity, Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" DisplayMemberPath="Name" HorizontalAlignment="Stretch" SelectionMode="Single"  Margin="125,100,0,10" VerticalAlignment="Top" Width="Auto" Grid.Column="0" Name="customerACB" SearchTextChanged="customerACB_SearchTextChanged" AutoCompleteMode="Suggest" >
                                        <telerik:RadAutoCompleteBox.DropDownItemTemplate>
                                            <DataTemplate>
                                                <StackPanel Orientation="Horizontal">
                                                    <Label Content="{Binding Code}" Width="70"  />
                                                    <Label Content="{Binding Name}" Width="310" />
                                                </StackPanel>
                                            </DataTemplate>
                                        </telerik:RadAutoCompleteBox.DropDownItemTemplate>
                                    </telerik:RadAutoCompleteBox>

 


Currently, i am able to search using "Name". If I change displaymemberpath to code it will show the result if the search string match with "code"
I need to search using both values "Name" and "code".

1 Answer, 1 is accepted

Sort by
0
Martin Ivanov
Telerik team
answered on 16 Dec 2022, 07:11 AM

Hello Ajay,

To achieve your requirement, you can implement custom filtering behavior. I hope that helps.

Regards,
Martin Ivanov
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
AutoCompleteBox
Asked by
ajay
Top achievements
Rank 1
Answers by
Martin Ivanov
Telerik team
Share this question
or