goodfutureahead
Member
- Joined
- Jun 14, 2010
- Messages
- 5
- Programming Experience
- Beginner
I have some datagridviews on a form which have a combobox column in them. It works but if there is no record found in the combo then a DataGridViewComboBoxCell is not valid error is given whenever the cursor passes over that field. I'd like to get rid of that error message. The thing is my dgv and the combo on it are entirely generated by code. I have found some error-trapping code on a Microsoft site but it is designed for a dgv on a form not generated by code. I don't know how to adapt it or if that can even be done. Could I generate one of these error handling routines for each dgv in code? How would you do that? Or is there another way to deal with this error?