mistermuv
September 7th, 2009, 05:59 AM
Hi
I have text file which I want to read into an ArrayList. Typically this would be straightforward and no problem however, what I am looking at doing is a little more complicated.
I want to search for a string "End of Error" and once this is found, which will be on a line on its own, is to then read the previous 6 lines into the ArrayList. The lines which hold the data to the error itself.
How would you go about this?
Thanks in advance.
I have text file which I want to read into an ArrayList. Typically this would be straightforward and no problem however, what I am looking at doing is a little more complicated.
I want to search for a string "End of Error" and once this is found, which will be on a line on its own, is to then read the previous 6 lines into the ArrayList. The lines which hold the data to the error itself.
How would you go about this?
Thanks in advance.