if (!Regex.IsMatch(diskName, @"^[c-zC-Z](:\\)?$")) { throw new FormatException($"{diskName} is not an effective disk name."); }
C# 正则表达式匹配盘符
猜你喜欢
转载自www.cnblogs.com/144823836yj/p/9656410.html
今日推荐
周排行