From: Hermann Martinelli Date: 2007-05-17T19:20:09+09:00 Subject: Re: Problem removing new line characters on Mac OS X Singeo wrote: > Hi Hermann, just tried your suggestion of: > > line.gsub!(/\015/, '') > > still no success. I'm creating and running the file on a Mac. Are you shure that you it is not successful? It would be good to know how you read the lines, how you (not) remove the carriage returns, and how you perhaps put the lines together (adding again \r characters by mistake?). Are you removing the carriage returns line by line (in which case the chomp should be perfect) or are you trying it as a whole, i.e. do you have not only one line but a whole file in 'line'? Rather than an answer to these questions I would prefer to see some more code of the whole part from opening the file to writing back or putting out the strings. Hermann