Also, you missed one of the "rea" in break. . . but I haven't looked at your code to answer your original question.

EDIT: Oh come on!!! do some good indenting. . . Boy howdy, that really hurts my eyes to even look at it!