[fpc-pascal] FreePascal Windows - Force files to write to disk
Santiago A.
svaa at ciberpiula.net
Wed Feb 22 09:47:34 CET 2017
El 21/02/2017 a las 22:12, James Richters escribió:
>
>
>
> Thanks for any advice on this
>
My first action would be to guarantee that the file is closed with a
try...finally.
AssignFile(BitFile,'BitSave.pax');
ReWrite(BitFile);
try
....
finally
CloseFile(BitFile);
end;
Second:
Do you have the file opened with an editor, or things like that, while
running the program?.
Third:
Check that all variables have valid values and that values are converted
to string properly to be printable.
Fourth:
Do you use somewhere {$I+} {$I-}? I also had some problems with that
with old programs.
Fourth:
What's the type BitFile?
BitFile: TextFile;
BitFile: File;
Maybe using writeln with non-textfile files may cause problems.
--
Saludos
Santiago A.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20170222/ccd9c640/attachment.html>
More information about the fpc-pascal
mailing list