Regular Expression Problem

  • Thread starter Thread starter Ken Brannigan
  • Start date Start date
K

Ken Brannigan

Hello All,
I am trying to create a regular expression that will match on the following
criteria:

1> It must be 7 numeric characters between 0 and 9.
2> No where can there be 4 consecutive zeros.

Match: 5551112
No Match: 5500001

If anyone can help me with this I would really appreciate it.
Thanks,
Ken
 
Well maybe this is too simple a solution, but why not convert it to a string
and then check for the existance of "0000" in the string ?

Ted
 
Back
Top