File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Java in General
Appending CR & LF to the end of a record
Joined: Aug 21, 2006
Jan 03, 2007 14:12:00
I need to append to the end of a record a Carriage Return (Hex 0D) for one byte and a Line Feed (Hex 0A) for one byte. It has to be in
type. Any ideas cowboys, cowgirls, and fellow rustlers? Thanks in advance....
"One man gathers what another man spills"
Joined: Jan 29, 2003
Jan 03, 2007 14:21:00
Hi, this one turns out to be easy if I read you right:
myString += "\r\n"; // or for better compatibility with at least the current system... myString += System.getProperties("line.separator");
[ January 03, 2007: Message edited by: Stan James ]
A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi
I agree. Here's the link:
subject: Appending CR & LF to the end of a record
Database file wrong, what should I do ?
How byte's are terminating the overflow value.
java.util.Scanner class - splitting a large text file
URLyBird 1.3.3 - Last Valid Flag is missing?!
Need to varify my file discriptor...
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015