Capturing a repeated group

后端 未结 9 1532
[愿得一人]
[愿得一人] 2021-01-14 09:17

I am attempting to parse a string like the following using a .NET regular expression:

H3Y5NC8E-TGA5B6SB-2NVAQ4E0

and return the following u

9条回答
  •  栀梦
    栀梦 (楼主)
    2021-01-14 09:19

    What are the defining characteristics of a valid block? We'd need to know that in order to really be helpful.

    My generic suggestion, validate the charset in a first step, then split and parse in a seperate method based on what you expect. If this is in a web site/app then you can use the ASP Regex validation on the front end then break it up on the back end.

提交回复
热议问题