| Author |
writing a newline char into a text file
|
samuel higgins
Greenhorn
Joined: Apr 21, 2003
Posts: 1
|
|
using the FileWriter class, how to you write a newline into a text file? I tried \n but in the text file i just get a little black box. thanks.
|
 |
Michael Morris
Ranch Hand
Joined: Jan 30, 2002
Posts: 3451
|
|
Wrap the FileWriter in a BufferedWriter and use the newLine() method. Something like this: [ April 21, 2003: Message edited by: Michael Morris ]
|
Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Ernst F. Schumacher
|
 |
Francis Siu
Ranch Hand
Joined: Jan 04, 2003
Posts: 867
|
|
hi samuel I have another method/suggestion to reference I hope that I can answer your question if you want to append the text to the text file please post a message again
|
Francis Siu
SCJP, MCDBA
|
 |
 |
|
|
subject: writing a newline char into a text file
|
|
|