function GetLineCount
lparam cFile
local nBytesCR, nBytesLF, nBytes, cLines
nBytes = 0
if vartype(cFile) == "C" .and. file(cFile)
cLines = filetostr(cFile)
nBytesCR = occurs(chr(13),cLines)
nBytesLF = occurs(chr(10),cLines)
nBytes = iif(inlist(right(cLines,1),chr(10),chr(13)),0,1)
nBytes = max(nBytesCR,nBytesLF) - nBytes
endif
return nBytes
endfunc