S
Schorschi
Not having used regular expressions much, I need some help.
Given a string... "This\0Guy\0Needs\0Some\0Help\0\0\0\0\0"
Need result as array of strings... "This","Guy", "Needs", "Some",
"Help"
Where '\0' is a literal zero-byte.
I think I need two regular expressions? One to strip the multiple
instances of '\0' bytes, and another to split the string.
Regex.Split works fine for the split, but I am having trouble getting
a regular expression to find the multiple '\0' instances, but leave
the single '\0' references alone.
Thanks!
Given a string... "This\0Guy\0Needs\0Some\0Help\0\0\0\0\0"
Need result as array of strings... "This","Guy", "Needs", "Some",
"Help"
Where '\0' is a literal zero-byte.
I think I need two regular expressions? One to strip the multiple
instances of '\0' bytes, and another to split the string.
Regex.Split works fine for the split, but I am having trouble getting
a regular expression to find the multiple '\0' instances, but leave
the single '\0' references alone.
Thanks!