Some columns in my grid are being added dynamically; their count and names come from a collection. All items in the grid have the same dynamic columns.
My data object looks like this:
class MyDataObject{ int ID; string Name; List<DynamicColumn> DynamicColumns;}/// <summary>/// Holds a value for a single dynamic column cell/// </summary>class DynamicColumn{ int DynamicColumnDefinitionId; // points to an item in a global collection that defines the dynamic columns for the whole grid. int Value;}The resulting grid could have these columns:
| ID | Name | DynamicColummn1 | DynamicColummn2 | ... |
My question:
How can I sort by one of the dynamic columns? Can I use a sort expression like "DynamicColumn[i]" ?
