So this is the Apple/Tech discussion forum so I hope this is okay here... it's more tech than Apple. Anyhow... I'm trying to get a regular expression to work. The expression is: Code: ^[^ES] This should match anything whose first character does not begin with E or S. I know the only data coming in will be E, S, M, and R1. In Perl this works just fine. But when I use the ".matches" method of String in Java it doesn't match R1! Granted I could do it with a simple if statement but I don't see why it won't work. Anybody?