This forum is cool, I often find the answer to my problem right after I post ;o)
I seem to have misunderstood how you implement the interfaces. Obviously you have to make the get/set methods return/set the same type that is defined by the cell.
Here’s my new implementation that works fine:
void ICellEditor.SetControlValue(object value, IFormatProvider customFormatProvider)
for (int i = 0; i < this.Items.Count; i++)
if (this.Items[i].Values.ToString() == (string)Convert.ChangeType(value, typeof(string), customFormatProvider))
this.SelectedItem = this.Items[i];
Imported from legacy forums. Posted by macke (had 2862 views)