日期:2014-05-18 浏览次数:20979 次
public string GetNextFileName(string currentName)
{
int index = 0;
Regex _reg = new Regex(@"(?<=\()\d+?(?=\))");
Match m = _reg.Match(currentName);
if (_reg.IsMatch(currentName))
{
index = int.Parse(m.Value);
index++;
}
return index.ToString();
}