Skip to content

Instantly share code, notes, and snippets.

@hmcclungiii
Created April 1, 2014 22:10
Show Gist options
  • Save hmcclungiii/9924148 to your computer and use it in GitHub Desktop.
Save hmcclungiii/9924148 to your computer and use it in GitHub Desktop.
Remove any non-numeric characters from a string.
string newValue = System.Text.RegularExpressions.Regex.Replace(oldValue, "[^.0-9]", "");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment