Hi,
I cannot find out how to get this to work.
I have a datagridview where user can fitter if based on some options they have. There is also a double-click feature that gets some additional info when a when a row is double-clicked. It is all good when no option is selected. But when the data source is changed, then the row index is still refers to the previous data even though the DGV is showing something else.
I might have misspoken by saying "filtered" as in fact I rebind the DGV with a new data source each time an option is selected:
Things are all good when the DGV is not "filtered", but when it is filtered the row index assumes the data from the original datagridview.
Can some one please help to find a solution to this?
Thanks in advance.
I cannot find out how to get this to work.
I have a datagridview where user can fitter if based on some options they have. There is also a double-click feature that gets some additional info when a when a row is double-clicked. It is all good when no option is selected. But when the data source is changed, then the row index is still refers to the previous data even though the DGV is showing something else.
I might have misspoken by saying "filtered" as in fact I rebind the DGV with a new data source each time an option is selected:
Code:
Dim MyBindingSource As New BindingSource()
MyBindingSource.DataSource = ThisTable
With ThisDGV
.DataSource = MyBindingSource
End With
Can some one please help to find a solution to this?
Thanks in advance.