I have a GridView where one of the columns is a GridViewComboBoxColumn.
After the grid has been populated by setting the DataSource to a list gotten from the database, I want to populate the ComboBox column.
The ComboBox column contains indexes(integers), which I want to be ValueMembers.
The ComboBox' DataSource is set to another list from the database, and the ValueMember and DisplayMember is set. But when setting the DisplayMember I get an exception saying "Object must be of type Int32". The DisplayMember I try to set is a string.
Is there a way to put a databound ComboBox in the column, where the value member is from one list and the display member from another?
Regards, Jill-Connie Lorentsen
After the grid has been populated by setting the DataSource to a list gotten from the database, I want to populate the ComboBox column.
The ComboBox column contains indexes(integers), which I want to be ValueMembers.
The ComboBox' DataSource is set to another list from the database, and the ValueMember and DisplayMember is set. But when setting the DisplayMember I get an exception saying "Object must be of type Int32". The DisplayMember I try to set is a string.
Is there a way to put a databound ComboBox in the column, where the value member is from one list and the display member from another?
Regards, Jill-Connie Lorentsen