using (StreamReader SR = new StreamReader(txtFileName)) { int row = 0; string line; while ((line = SR.ReadLine())!= null) { string[] Columns = line.Split(','); dataGridView2.Rows.Add(); for (int i = 0; i < Columns.Length; i++) { dataGridView2[i, row].Value = Columns[i]; } row++; } }
string[] Columns = line.Split(',');
string[] Columns = line.Split(' ');
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)