View Single Post
  #2 (permalink)  
Old 11-15-2007, 04:32 PM
ShoeNinja's Avatar
ShoeNinja ShoeNinja is offline
Senior Member
 
Join Date: Oct 2007
Posts: 123
ShoeNinja is on a distinguished road
Send a message via AIM to ShoeNinja
Look at the methods of the String class. I think you can use the replace method since \n is an escape character. If not, you can do something like this:

Code:
int i = line.indexOf("\n"); line = line.subString(0, i); //may be i - 1
As far as your code is concerned, what is broken about it?
Reply With Quote