Question : Read all data from a datagridview and copy it to a public array or something like that...

Hi folks!

I got a Datagridview with 4 columns in total. How do I pass all the contents of it into a public array or any easy-to-read list?

My idea is to use that array to perform different windows file system operations like copy and paste and the paths for all file locations will be inside the array. Any Ideas?

Thanks in Avance,

Angel

Answer : Read all data from a datagridview and copy it to a public array or something like that...

If you want to capture cells do like this:

       Dim c As DataGridViewSelectedCellCollection = DataGridView1.SelectedCells
       For i = 0 To c.Count - 1
           Dim s As String = c(i).Value.ToString()
       Next

Random Solutions  
 
programming4us programming4us