RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Expressions by User

   Displaying page 1 of 1 pages; Items 1 to 1
Title Test Details UserId Validation
Expression
^(?=.*[a-zA-Z])[^\*\s]{4,8}$
Description
Validates a userID to be between 4 and 8 characters - no whitespace or asterisks and at least one alpha. ^(?=.*[a-zA-Z]) searches for one alpha [^\*\s] rejects all white space and asterisks {4,8} limits from 4-8 characters.
Matches
!@#a asdf 1234a
Non-Matches
!@#$* !@#4*a #$%a # asd 12345678a
Author Rating: Not yet rated. Nancy Blackwell
   Displaying page 1 of 1 pages; Items 1 to 1

Copyright © 2001-2025, RegexAdvice.com | ASP.NET Tutorials