string s = "rohan%9999gupta-#999999";
var output = Regex.Replace(s, "[^0-9]+", string.Empty);This code snippet for get numeric value from Alphanumeric string in C#.
This code snippet for get numeric value from Alphanumeric string in C#.
string s = "rohan%9999gupta-#999999";
var output = Regex.Replace(s, "[^0-9]+", string.Empty);