数字正则表达式验证器

我需要一个正则表达式验证

numeric digits grouped as X-XXXXX-XXX-X

任何人都可以帮忙吗?

采纳答案:
Regex reg =  new Regex("\b[0-9]\-[0-9]{5}\-[0-9]{3}\-[0-9]\b");
author: ravi-gadag

参考更多解答: Digits Regular Expression Validator ,转载请保留出处数字正则表达式验证器及作者信息

Statement: We respect knowledge and authors. Since the content comes from the Internet and is intended for scientific research, any reprinters should retain the author's signature and origin. If you are the author of the content and feel in dispute, please contact email: 1076545519@qq.com. We will find out the situation and deal with it in time. We sincerely thank the author for his hard work.


更多:regex