I want to add a ComboBoxCell showing a value with a dropdown of other possible values.
The thing is, that the possible values differ for each row in my grid view, so an approach like this will not work.
grid.Columns.Add(new GridColumn
{
DataCell = new ComboBoxCell
{
Binding = Binding.Property<MyPoco, object>(r => r.AnyValue), // ok
DataStore = new string[] { "abc", "def", "ghi" } // static
}
});
So I think I might need any expression like used for the Binding
, like so ...
grid.Columns.Add(new GridColumn
{
DataCell = new ComboBoxCell
{
Binding = Binding.Property<MyPoco, object>(r => r.AnyValue),
DataStore = Binding.Property<MyPoco, IEnumerable<string>>(r => r.MyValueList)
}
});
... but that does not even compile. Does anyone know how to achieve this?
Please feel free to respond to my question on StackOverflow as well, to get some reputation ;)