SyntaxFix
Write A Post
Hire A Developer
Questions
With LINQ, you could use the SkipWhile / TakeWhile methods, like this:
SkipWhile
TakeWhile
var importantLines = File.ReadLines(pathToTextFile) .SkipWhile(line => !line.Contains("CustomerEN")) .TakeWhile(line => !line.Contains("CustomerCh"));