Xabier Oneca -- xOneca wrote: >You should break from 'while' too (using evil goto?). No need to >continue reading the file if you don't want count > MAXLINES (in fact, >in your code, count will be incremented past MAXLINES in the next >read). Good catch, thank you. I'm looking at it now: a goto should do the trick. Ron