Ant
Member
I have a string "X = 1800.000, Y = 321.359, Z = -900.000," that I'm trying to split and load into a list Object.
This only gets me the whole decimal number, not the negative sign.
I've tried the following without success, probably a worse result, the Split seemed random or failed to get the numbers.
I'm building my project in C# net 4.7.2 , do I need to use a different expression?
This only gets me the whole decimal number, not the negative sign.
C#:
Regex.Split(strGrp2, @"[^\d.]+");
I've tried the following without success, probably a worse result, the Split seemed random or failed to get the numbers.
C#:
@"(?<!\d.+)-?"
@"-?[0-9]*\.?[0-9]"
I'm building my project in C# net 4.7.2 , do I need to use a different expression?