Hi I am converting a old vb.net program to WPF and am having trouble. I imported some data to a datatable and dumped that into a datagrid. I now need to go row by row and extract the cell values and use them to update the appropriate database record.
This was working in my old program using:
For i = 0 To DataGridView1.Rows.Count - 1
cellvalue = Me.datagrid.Items(i).Cells(8).Value).ToString
(insert to database) etc
next
I been searching around and apparently its not as simple in WPF. But all the working examples i can find are all in C# which I am not that famillar with and cant seem to convert to work. So if someone can provide me some code (in vb) that would be much appreciated.
If you’ve already got a DataTable that contains your data, it is pretty easy to work with that: