Capturing a repeated group

后端 未结 9 1634
[愿得一人]
[愿得一人] 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:31

    Sorry if this isn't what you intended, but your string always has the hyphen separating the groups then instead of using regex couldn't you use the String.Split() method?

    Dim stringArray As Array = someString.Split("-")
    

提交回复
热议问题