0

我试图在Last Backup:和结局之间span

但我得到了空白值?

string test = @">Last Backup: 4/27/13</span></";

string regex = @"(?<=Last Backup: )*.(?='</span')";

var match = Regex.Match(test, regex);

Console.WriteLine(match.Value);
4

1 回答 1

0

Try this: (?<=Last Backup: ).*(?=\</span)

Errors :

  • you have inverted .*
  • you have put ' around </span
于 2013-05-30T08:30:05.090 回答