Sufi,
In Dos end of line is \r\n
in Unix end of line is \r
in Mac is \n
I hope it will help
Angel
----- Original Message -----
From: "sufi malak" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, February 14, 2002 9:17 PM
Subject: Re: reading text file ?


> I tried trim(), but it does not work, it looks like it's a format problem,
> since if I hit enter in each line then take off the line created, how to
do
> this for the string in the class ?
>
> thanks
>
>
> >From: Richard Yee <[EMAIL PROTECTED]>
> >Reply-To: A mailing list about Java Server Pages specification and
> >reference <[EMAIL PROTECTED]>
> >To: [EMAIL PROTECTED]
> >Subject: Re: reading text file ?
> >Date: Thu, 14 Feb 2002 11:44:00 -0800
> >
> >Sufi,
> >I assume you are reading each line as a String. If so, use the
> >String.trim() method to strip off any whitespace from your String.
> >
> >-Richard
> >
> >
> >At 07:24 PM 2/14/2002 +0000, you wrote:
> >>Hi,
> >>I have a text file that has more than 800 lines, I wrote a program to
read
> >>line by line and process it, the file is like this :
> >>
> >>15510862
> >>15510863
> >>155108610
> >>..........
> >>
> >>But when read it it looks like every line has something appended to ,
> >>maybe
> >>an end of line. When I go to the end of each line and hit "return"
> >>then take off all the lines created after hitting "return" it works
fine.
> >>Could you help please.
> >>Thanks
> >>
> >>
> >>
> >>
> >>
> >>_________________________________________________________________
> >>Get your FREE download of MSN Explorer at
> >>http://explorer.msn.com/intl.asp.
> >>
>
>>==========================================================================
=
> >>To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> >>JSP-INTEREST".
> >>For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
> >>DIGEST".
> >>Some relevant FAQs on JSP/Servlets can be found at:
> >>
> >>http://archives.java.sun.com/jsp-interest.html
> >>http://java.sun.com/products/jsp/faq.html
> >>http://www.esperanto.org.nz/jsp/jspfaq.jsp
> >>http://www.jguru.com/faq/index.jsp
> >>http://www.jspinsider.com
> >
>
>===========================================================================
> >To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> >JSP-INTEREST".
> >For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
> >DIGEST".
> >Some relevant FAQs on JSP/Servlets can be found at:
> >
> >http://archives.java.sun.com/jsp-interest.html
> >http://java.sun.com/products/jsp/faq.html
> >http://www.esperanto.org.nz/jsp/jspfaq.jsp
> >http://www.jguru.com/faq/index.jsp
> >http://www.jspinsider.com
>
>
> _________________________________________________________________
> Get your FREE download of MSN Explorer at
http://explorer.msn.com/intl.asp.
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://archives.java.sun.com/jsp-interest.html
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.jsp
>  http://www.jguru.com/faq/index.jsp
>  http://www.jspinsider.com

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://archives.java.sun.com/jsp-interest.html
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.jsp
 http://www.jguru.com/faq/index.jsp
 http://www.jspinsider.com

Reply via email to