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 Pattern Title
Expression
^\\{2}[\w-]+\\(([\w-][\w-\s]*[\w-]+[$$]?$)|([\w-][$$]?$))
Description
Validates a UNC to conform to \\server\service Must have a "\\" at the start Server may contain alpha/numeric/underscore/dash, Followed by another single "\" Service may contain alpha/numeric/underscore/dash/$/space Note: Service may not start nor end with a space Service may only contain one $, and only at the end No additional "\" may follow afterwards
Matches
\\server\service | \\server\my service | \\serv_001\service$
Non-Matches
\\my server\service | \\server\ service | \\server$\service
Author Rating: The rating for this expression. Paul Haines
   Displaying page 1 of 1 pages; Items 1 to 1

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