First, when you do "if(readArray[i] =="Exit" ) break;", you don't actually check the value of the string, rather the position in the memory. To check the actual value, use readArray[i].equals("Exit").
Second, you need to place your if statement after your input. As it is now, at your if statement, readArray[i] is null, since you haven't done anything with it yet. So your if-statement will never be true.
Aviras
Junior Poster in Training
82 posts since Jul 2008
Reputation Points: 24
Solved Threads: 8