>>Is a way I can find the number of lines in a text file ?
>
>Probably just like a memofield. Use FileToStr() to get a string, then use MLINES or MemLines or whatever it is. But this may depend on _mline or whatever it is (sorry I'm not totally sure), so you could use Alines() to be sure.
>
>
Alines(laA, FileToStr('mytext'))
>?alen(laA, 1)
aLines() function will chop it along the chr(13) boundaries, while it's not sure what the definition of a line may be in this case. I'd recommend to Set Memo To [whatever_value_you_like] and use MemLines(lcString) to determine the number of lines. If number of CRs is needed, occurs(chr(13), lcString) would be much faster than aLines(), unless we'd really have some use for the array aLines() will create. BTW, aLines() is limited to 65000 :)