galmos (1) [Avatar] Offline
Hi, i would like to create a DataGridView with a list of Client entities. This Client entity has an IdState foreign key to a related table with the list of states (IdState, Description colums).

I have successfully created a DataGridView with a ComboBox showing state description instead of Id. But as I would like the DataGridView to be read-only, showing a combobox makes the user think he can edit the cell. So to avoid this user behaviour, I would like to have a textbox where the state description would appear.

My problem is that I can't find a way to assign the textbox the value of the state description.

Making an anonymous type with linq solves the problem when viewing data. But I would like to allow databinding to refresh data from an external detail form.

Is there any way to do this?

Thank you