Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

I get Illegal Escape Character, compile time error...regular expressions

807580Mar 12 2010 — edited Mar 12 2010
I'm trying to check whether the String line matches a format e.g. X12345,98 or X23425, 9 etc... using regular expressions
I use Jcreator and it doesnt tell me which one has a problem.
if(line.matches("[a-zA-Z][\d]{5}[,][\d]{1,3}")){
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 9 2010
Added on Mar 12 2010
4 comments
274 views