Regular Expression to validate
Posted: Thu Aug 12, 2010 8:06 am
Hi
Suggest a Regular Expression to validate the following criteria:
For a text box,
User can pass
1. empty value or
2. Enter 9 digits or
3. Enter 9 digits followed by comma and space and another set of 9 digits (4 times)
Eg:
User can enter
OR
123456789 OR
123456789, 123456789 OR
123456789, 123456789, 123456789 OR
123456789, 123456789, 123456789, 123456789 OR
123456789, 123456789, 123456789, 123456789, 123456789
Suggest a Regular Expression to validate the following criteria:
For a text box,
User can pass
1. empty value or
2. Enter 9 digits or
3. Enter 9 digits followed by comma and space and another set of 9 digits (4 times)
Eg:
User can enter
OR
123456789 OR
123456789, 123456789 OR
123456789, 123456789, 123456789 OR
123456789, 123456789, 123456789, 123456789 OR
123456789, 123456789, 123456789, 123456789, 123456789