Thank you for using Syncfusion controls.
In ComboBox controls items are generated by added orders only. In FilterRow, we have used the ComboBoxAdv control. So, it shows the orders based on manner, which you added in its itemsSource.
Now, we have ordered this by apply the sorting for comboBoxItems. We have achieved this by overriding the GridFilterRowMultiSelectRenderer.
|
Grid.FilterRowCellRenderers.Remove("MultiSelectComboBox");
Grid.FilterRowCellRenderers.Add("MultiSelectComboBox", new GridMultiSelectComboBoxRendererExt());
public class GridMultiSelectComboBoxRendererExt : GridFilterRowMultiSelectRenderer
{
public GridMultiSelectComboBoxRendererExt() : base()
{
}
public override void OnInitializeEditElement(DataColumnBase dataColumn, ComboBoxAdv uiElement, object dataContext)
{
base.OnInitializeEditElement(dataColumn, uiElement, dataContext);
SortDescription sd = new SortDescription("DisplayText", ListSortDirection.Ascending);
uiElement.Items.SortDescriptions.Add(sd);
}
} |
Please check the sample and let us know if you need further assistance on this.
Regards,
Susmitha S