[Solved] How split space to fill dataGridView from file .txt in C#

[ad_1]

Take look on line string[] Columns = line.Split(‘,’);
You try to split line by comma, but no commas in the file. Try split by space.
Like

string[] Columns = line.Split(' '); 

Or

string[] Columns = line.Split(new []{' '}, StringSplitOptions.RemoveEmptyEntries)

1

[ad_2]

solved How split space to fill dataGridView from file .txt in C#