Got more questions? Find advice on: ASP | SQL | XML | Windows
Welcome to RegexAdvice Sign in | Join | Help

Re: Regular Expression that does not equal an input

  •  05-08-2007, 12:29 PM

    Re: Regular Expression that does not equal an input

    Try something along the lines of

    ^(?!something).*$
    Edit:

    Lyndar was first. Big Smile Don't forget to escape the user supplied input string. Pattern.quote(String s) will put start and end of line assertions around the string though.

    Filed under:
View Complete Thread