How to get the number of lines in the file quickly!
Posted: Thu Oct 02, 2003 2:44 pm
Sorry for my poor English!
Anyone can show me a way to get how many lines in a file quickly.
I'm using a stupid solution:
Thanks!
Anyone can show me a way to get how many lines in a file quickly.
I'm using a stupid solution:
Code: Select all
If ReadFile(0, GetGadgetText(#TextFilename))
k.l=0
While Eof(0)=0
InfoString$ =ReadString()
k.l=k.l+1
Wend
SetGadgetText(#TextBX, Str(k.l))
Debug "File opened successfully"
Else
Debug "Faint!It's impossible:P"
EndIf