Hi Ondrej Svoboda,
We have reviewed your query, and based on your requirements, dynamic values in the MultiSelectComboBox filter row editor can be implemented by overriding the InitializeEditBinding method in the GridFilterRowMultiSelectRenderer class. When a filter is applied to the Country column (for example, selecting Mexico), the Customer Name column editor will populate only with the records currently displayed in the grid view, instead of showing all records.
Code Snippet to Display Dynamic values in MultiSelectComboBox FilterRow Editor:
datagrid.FilterRowCellRenderers.Remove("MultiSelectComboBox"); datagrid.FilterRowCellRenderers.Add("MultiSelectComboBox", new DynamicMultiSelectRenderer());
public class DynamicMultiSelectRenderer : GridFilterRowMultiSelectRenderer { protected override void InitializeEditBinding(ComboBoxAdv uiElement, DataColumnBase dataColumn) { -----------------Code Changes-------------------------
uiElement.ItemsSource = itemsCollections;
-----------------Code Changes-------------------------
} } |
Gif Illustration:

Please find the sample demo in the attachment.
Regards,
Senthilkumar Ranganathan.
Attachment:
SfDataGrid_Demo_99e6f10a.zip