.NET 3.5
I need to attach an object to each row in a DataGridView. I thought it should be any property for doing it but I cant find it. How is it done?
(Btw in this case Im not connecting to any DataSet.)
Printable View
.NET 3.5
I need to attach an object to each row in a DataGridView. I thought it should be any property for doing it but I cant find it. How is it done?
(Btw in this case Im not connecting to any DataSet.)
You should be able to extend the row with your own custom data type
You mean creating a custom class that derives from the DataGridViewRow?
If you need to add smething to a dgvrow you ned to create a dgv Column
In this column cell you cann add your object.
If you are using the ToString() property of your object and the class you are adding overrides its ToString() method then you will be able to see your class and having a meaningfull name of the instance in each row.