C# Reading only specific lines without reading line by line
I been googling for the last hour and can not find an answer to this.
I have a large text file (1GB) and I also have a file which has this all
mapped so I know that on line x to line y it contains the data I am after.
My question is how do I take only the lines I am interested in without
iterating through all the lines in the file?
The main reason I am interested in doing it this way is for performance
reasons, I imagine it be quicker to take rows 503,432 to row 504,432 than
cycle from row 1 to 504,432 to find these rows.
Any tips much appreciated
No comments:
Post a Comment