* * *

Author Topic: [SOLVED] Using TFileStream to write plan old text files  (Read 3353 times)

Thaddy

  • Hero Member
  • *****
  • Posts: 5984
Re: Using TFileStream to write plan old text files
« Reply #15 on: August 05, 2017, 10:59:58 am »
Ah, I see what you mean. Might suit some others but certainly not me. I'm writing out some xml to be read in another application so must be plain old text file I'm afraid.
If you are writing xml, just use a TFilestream and  write buffered, do not use the string functions in that case.
Point is: XML doesn't care about line endings or zero termination at all, so provided your other application expects valid XML that should simply work.
You will loose some text formatting (not within the XML tags, though), but that formatting is not part of XML itself..... It is just to make it easy on the eyes.
I might not give the answer that you want me to.. Peter Green 1969

 

Recent

Get Lazarus at SourceForge.net. Fast, secure and Free Open Source software downloads Open Hub project report for Lazarus