I have a class with three property
Class MyTest
{
String MySting {get; set;}
Bool MyBool {get; set;}
DateTime MyDateTime{get; set;}
SampleType MyType{get; set} //SampleType is a enum
}
Now I create myCollection with 5 MyTest objects. Then I call ultraGrid1.DataSource = myCollection;
I run the program and I can see that the column related to MyBool property is correctly shown as a CheckBox in the cell, and MyDateTime is shown correctly as DateTime control in the cell.
MyType property is shown as string in the cell, but I expect it to be a dropdown ComboBox in the cell abd populated the comboBox with enum items. How can I realize it?
I finally figure out the trick.
create a valueList vl, and populated vl with enum names, then assign vl as:
ultraGrid1.DisplayLayout.Bands[0].Columns["MyType"].ValueList = vl;
Hope ther is a easier way.
HOWTO:What is the best way to place a DropDown list in a grid cell?