aspose file tools*
The moose likes Java in General and the fly likes not getting howdy and folks in the new line, string related from  scjp6.0 book Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "not getting howdy and folks in the new line, string related from  scjp6.0 book" Watch "not getting howdy and folks in the new line, string related from  scjp6.0 book" New topic
Author

not getting howdy and folks in the new line, string related from scjp6.0 book

Vishal Hegde
Ranch Hand

Joined: Aug 01, 2009
Posts: 1055



i anm not getting howday and folks in the new line but special charecter is being displayed in the notepad in place of \n


http://www.lifesbizzare.blogspot.com || OCJP:81%
Pushkar Choudhary
Rancher

Joined: May 21, 2006
Posts: 425

Vishal Hegde wrote:i anm not getting howday and folks in the new line but special charecter is being displayed in the notepad in place of \n

Just tested this. Works fine for me. the two words are on different lines and the second line starts with a space.
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Could also be an encoding issue--try opening the file with a real editor, or just listing it to the command window.
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19718
    
  20

Notepad requires \r\n as line separators. Only \r or \n results in a little square. Use a proper editor like Notepad++ instead of Notepad. Notepad is just worthless, and shouldn't be used at all unless you have no other choice.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: not getting howdy and folks in the new line, string related from scjp6.0 book