Hi folks, I'm an italian customer and I apologize for non correct english language.
I have a little problem with the LF (line feed character).
I must write an application (for Mac Os and Windows) who generate a text data (such a geometrical data).
At the end of each line of the data there must be a return character, while at the beginning of each line must be a LF (line feed) character numToChar(10).
I can not enter the numToChar(10) in the my file:
open file "ATest.txt"
write numToChar(10) & space & Xdata & space & Ydata & return to file "ATest.txt"
close file "ATest.txt"
Also if I use the CRLF function, only a return char is present enter the file (not the line feed).
When I open this file with a text editor application (Text-Edit Plus), no line feed character is present.
Can you help?
Line feed in text file
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- VIP Livecode Opensource Backer
- Posts: 1236
- Joined: Sat Apr 08, 2006 1:10 pm
- Location: Zurich
- Contact:
runrev automatically translates end of line characters (return and linefeed) into the current platform's preferred ones. to prevent that, you need to open the file for binary. (see the "open file" entry of the documentation for more details)
Various teststacks and stuff:
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode