Dim dtModifiedData As DataTable = dtMain.GetChanges(DataRowState.Modified)
As the definition of the function says, it does copy the rows after filtering it from the main table.
Is it possible to get them by reference?
Yes:
Dim modifiedRows = From row In dtMain.AsEnumerable()
Where row.RowState = DataRowState.Modified
If you need it in a DataTable, that's not possible because a DataRow always belongs to one DataTable. If you try to move it from one to another you'll get an exception. You need a method like ImportRow which creates a new DataRow with the values from the source-row. For the same reason CopyToDataTable on above LINQ query will also create new DataRows.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With