Sort a Blazor DataGrid column with custom logic - supply your own IComparer to order values any way you need, such as ordering ids by their mapped display name. Custom comparers apply to in-memory data only.
Reference | Priority |
|---|---|
| ORD-001 | Urgent |
| ORD-002 | Normal |
| ORD-003 | Critical |
| ORD-004 | Normal |
| ORD-005 | Urgent |
Set the column's SortComparer to an IComparer implementation; the grid uses it instead of the default comparison.
Radzen Blazor Components, © 2018-2026 Radzen.
Source Code licensed under
MIT