extracting text

hello,

i want 2 extract some data from a text file. an example is this:

******

ISBN ################## 0760049602.

*******

# means any number of blank spaces

the problem is that there can be any number of blank chars between

the "isbn" and the actual no which is unreliable can be 1space,

2space etc.. it normally gives atleast 7 space chars and so the program

cannot/does not extract the isbn no. here is the code:

**********

int end=0;

while(end >= 0){

int begin = read.indexOf("ISBN",end);

if (begin >= 0){ begin++;

end = read.indexOf('.',begin);

}

if(end >= 0){

String ISBNresult = read.substring(begin,end);

isbnVector.add(ISBNresult);

}

}

else {end = -1;}

}

***********

the above code does not return any isbn nos.

pls can some one help as i need to extract the isbn numbers...

someone advised to use : split("[\\s]+"); BUT I AM NOT SURE WHERE TO USE IT...

[1045 byte] By [moh_1_and_onlya] at [2007-11-27 1:14:31]
# 1
Stop wasting people's time please.Just continue the discussion in your previous thread: http://forum.java.sun.com/thread.jspa?threadID=5161164or this one: http://forum.java.sun.com/thread.jspa?threadID=5160794You got perfectly good answers in both!
prometheuzza at 2007-7-11 23:49:51 > top of Java-index,Java Essentials,Java Programming...