Horodyski Marek (PZUZ) wrote:
I'm old and stupid, and looking for an error of where he was not found
:)
1. Mlcount() on Win gives the wrong number of lines, if there is a chr
(10) only as eof - like in file
C:\harbour\contrib\rddsql\tests\test1.prg
    (i have function like hb_run, that use MlCount()).

There has been an extension to the memo functions that accepts an extra parameter being either string specifying the EOL string or an array of EOL strings.

The previous of this did not handle the array properly but this has been fixed. Obviously a recent build is needed. If you have an old build, pass chr(10) but be prepared to handle the chr(13) from Win/Dos files


  LOCAL nLines := mlcount(@cMemo, nMaxLine, 1, .F., chr(10) )
or
LOCAL nLines := mlcount(@cMemo, nMaxLine, 1, .F., { chr(13) + chr(10), chr(10), chr(13) } )

April

--
... File not found. Should I fake it? (Y/N)

_______________________________________________
Harbour mailing list
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to