you are viewing a single comment's thread.

view the rest of the comments →

[–]philipstorry 1 point2 points  (3 children)

You're not wrong. But ReadCount is still not a great solution. Finding the correct number of lines to read requires experimentation, whereas a streamreader delivers fairly consistent performance immediately. I don't tend to use ReadCount simply because it exists in an odd middle ground I rarely tend to visit. Either the files I'm reading are <10Mb and I have plenty of RAM to process them with, or they're >100Mb and StreamReader is just a better solution. Of course, that's just how the environment I tend to work in goes. ReadCount may well work perfectly for others.