'How can i extract a return string from a Regex Match in C#? [duplicate]
I would like to extract from a Regex Match a string return. The code is that:
public static string timeConversion(string s)
{
CultureInfo converter = new CultureInfo("pt-BR");
var conv = DateTime.Parse(s, converter).ToString();
var reg = new Regex("[0-9]{2}:?[0-9]{2}:?[0-9]{2}");
var regRes = reg.Matches(conv);
return (i don't know)
}
I wish to return a string with the value, for example: "21:53:09"
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
