日期:2014-05-18 浏览次数:20795 次
string s = "123:234;321:123;789:987;"; Match m = Regex.Match(s, @"321:(\d+)"); Console.WriteLine(m.Groups[1]);
------解决方案--------------------
string result = Regex.Match(yourStr,@"(?<=321:)\d+").Value;
------解决方案--------------------
string pattern=@"^\d{3}:\d+$";