111,098
社区成员




static public string GetMatch(string input, string pattern)
{
Regex re = new Regex(pattern);
Match myMatch = re.Match(input);
if (myMatch != null)
{
return myMatch.Value;
}
else
{
return "";
}
}
strContent = " 121.189.226.72 1253432292 1253432292\r\n";
string strMatch = GetMatch(strContent, @".*(?:(\r\n))");
strContent = " 121.189.226.72 1253432292 1253432292\r\n";
string strMatch = GetMatch(strContent,@".*(?=\r\n)");