5 Answers, 1 is accepted
Hi Usman,
To achieve this behavior you will need to extract and edit the default template of the control. You can take a look at the Editing Control Templates help article which describes how you can get the default template of the controls. More specifically, you will have to modify the template of the SearchAutoCompleteBox inside the control. You can modify this element template to add a button at the end of the search part.
To remove the close button inside the selected item, you can set the SelectionBoxesVisibility property of the RadMultiColumnComboBox to Collapsed.
<telerik:RadMultiColumnComboBox SelectionBoxesVisibility="Collapsed" SelectionMode="Single"> . . .
Regards,
Dinko
Progress Telerik
Our thoughts here at Progress are with those affected by the outbreak.
Hello Louay,
This behavior could be observed when the SelectionBoxesVisibility is set to Collapsed/Hidden and AutoCompleteMode is Search/Suggest. It is already logged in our Feedback Portal, where you can track its progress.
As a workaround, you can try using the following implicit style, which targets the SearchAutoCompleteBoxItem element. In the implicit Style, you can override the Template and place inside TextBlock. The Text property of the TextBlock will be bind to the property of the selected item.
<Style TargetType="telerik:SearchAutoCompleteBoxItem">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate>
<TextBlock Text="{Binding "Your Property here. In this case, can be Name as DisplayMemberPath" }"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
Regards,
Dinko
Progress Telerik
Our thoughts here at Progress are with those affected by the outbreak.
Thanks Dinko,
If I use implicit style? is there a way to use the DisplayMemeberPath in the Binding? Otherwise I have to use a common filed name in all my MultiComboBoxes.
Hello Dinko,
Issue resolve, I used ContentPresenter instead of TextBlock. And now the DisplayMemberPath is working.
<
Style
TargetType
=
"telerik:SearchAutoCompleteBoxItem"
>
<
Setter
Property
=
"Template"
>
<
Setter.Value
>
<
ControlTemplate
TargetType
=
"telerik:SearchAutoCompleteBoxItem"
>
<
ContentPresenter
/>
</
ControlTemplate
>
</
Setter.Value
>
</
Setter
>
</
Style
>