Thursday, September 13, 2018

How to read from a flat file n number of lines in in C# and how to add all of an IEnumerable to a List in C#.

IEnumerable lines = File.ReadLines(fromPath).Skip(counter).Take(1000);
list.AddRange(lines);

No comments:

Post a Comment