Discussions about product bugs & problems!
Note: This is no replacement for the Official ETM Support!
5 posts • Page 1 of 1
5 posts
• Page 1 of 1
Dag-Are.Trydal@nov.com
Posts:37
Joined: Fri Feb 26, 2016 11:52 am
Cartridge Return & Line Feed
Postby Dag-Are.Trydal@nov.com »
When saving a file (using fclose(f)) where I have used only "\\n" as newline I get CRLF in the file.
But when saving an XML (using xmlDocumentToFile(docNum,fileName)) it is saved with only LF.
The reason is that some service personell have to edit this settings-xml from time to time. And windows nodepad (not notepad++) displays it on one line when it is only LF.
Following Ideas (I'm not on windows so I did not test it):
- When the personell uses WinCC_OA itself to edit the file, you could try the CTRL function textEditor() instead
- When this does not work, try using xmlDocumentToString() and then do a
f = fopen(name, "w"); fprintf(f, "%s", theString); fclose(f);
I assume this will create CRLF on windose