>>Thanks, Sergey. I guess, it's not a big of a deal if some information would not end up in the log. I don't think this situation would ever occur.
>>
>
>Are you using STRTOFILE() in append mode?
Yes.
procedure WriteToLogfile
lparameters tcstring, tlNoTime
if m.tlNoTime
=strtofile(m.tcstring + CRLF, this.cLogFileDir + this.cLogFile, 1)
else
=strtofile(ttoc(datetime()) + " " + ;
m.tcstring + CRLF, this.cLogFileDir + this.cLogFile, 1)
endif
endproc
I may try to change this code to do it in cycle. Do you think it's necessary?
Well, reading Help helps <g>
Unlike earlier versions of Visual FoxPro, STRTOFILE( ) opens a file in Shared rather than Exclusive mode. This is useful when multiple servers attempt to simultaneously write to the same file. Because of this change, you might not need to check for STRTOFILE( ) to return 0 (failure to open a file). I also made a change to use just one line of code with iif rather than if/else/endif
If it's not broken, fix it until it is.
My Blog