Earn income with your C# skills
Sign up and we'll send you the best freelance opportunities straight to your inbox.
We're building the largest self-service freelancing marketplace for people like you.

How to create a C# Regex that accepts numbers only (0-9) and no characters.

The Regex is: ^[0-9]*$

^ Matches the beginning of the string, or the beginning of a line if the multiline flag (m) is enabled. This matches a position, not a character.

[0-9] Matches a character having a character code between the two specified characters inclusive.

* Matches 0 or more of the preceding token.

$ Matches the end of the string, or the end of a line if the multiline flag (m) is enabled. This matches a position, not a character.




Stay Inspired!
Join other developers and designers who have already signed up for our mailing list.
Terms     Privacy     Licensing       EULA       Sitemap      
© Data & Object Factory, LLC.
Made with    in Austin, Texas.      Vsn 1.3.0